Sha256: eff1724ae3fa7754214a4de52bf62c69f9195807fdb0ae02fa46db957a5ba3e0

Contents?: true

Size: 395 Bytes

Versions: 1

Compression:

Stored size: 395 Bytes

Contents

#!/usr/bin/env ruby
require "jflow"
require "slop"

opts = Slop.parse do |o|
  o.string '-f', '--file', 'worker configuration file'
end

raise "You need to specify a file!" unless opts[:file]

configuration = JSON.parse(File.read(opts[:file]))

cli = JFlow::Cli.new(configuration)

["INT", "TERM"].each do |signal|
  Signal.trap(signal) do
    cli.shutdown_workers
  end
end

cli.start_workers

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
jflow-0.2.8 bin/jflow_worker