Sha256: fc5ed067534f03d83e3feb67fdf87af39258ca325f751d31e382c0d3c2705e87

Contents?: true

Size: 549 Bytes

Versions: 8

Compression:

Stored size: 549 Bytes

Contents

module Larva
  class Daemon
    def self.start(*args)
      daemon = new(*args)
      daemon.configure
      daemon.start
      daemon
    end

    # Allowed Options:
    #   :env - Defaults to development
    def initialize(processors, options = {})
      @processors = processors
      @options = options
    end

    def start
      Filum.logger.info "Starting Workerpool"
      Larva::WorkerPool.start(@processors)
      Filum.logger.info "Workerpool Finished"
    end

    def configure
      Configurator.configure(@options)
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
larva-1.3.0 lib/larva/daemon.rb
larva-1.2.0 lib/larva/daemon.rb
larva-1.1.3 lib/larva/daemon.rb
larva-1.1.2 lib/larva/daemon.rb
larva-1.1.1 lib/larva/daemon.rb
larva-1.1.0 lib/larva/daemon.rb
larva-1.0.1 lib/larva/daemon.rb
larva-1.0.0 lib/larva/daemon.rb