lib/bluth/cli.rb in bluth-0.6.1 vs lib/bluth/cli.rb in bluth-0.6.7

- old
+ new

@@ -31,23 +31,25 @@ worker = worker_class.new Familia.info "Created: #{worker.rediskey}" worker.daemonize worker.run else - Bluth.poptimeout = 3.seconds + Bluth.queuetimeout = 3.seconds worker_class.run end end def stop_workers worker_class=Bluth::Worker + Bluth.connect worker_class.instances.each do |worker| kill_worker worker, worker_class end end def stop_worker wid=nil,worker_class=Bluth::Worker wids = wid ? [wid] : @argv + Bluth.connect wids.each do |wid| worker = worker_class.from_redis wid kill_worker worker, worker_class end end @@ -62,10 +64,10 @@ if worker.nil? Familia.info "No such worker" exit 1 else Familia.info "Killing #{worker.rediskey}" - worker.kill @global.auto + worker.kill @option.force end end end end