Sha256: edaf6388af9719b6f2008a27879e2c4c93affdecab1b0df531ce3fb71e093846
Contents?: true
Size: 330 Bytes
Versions: 9
Compression:
Stored size: 330 Bytes
Contents
require 'rubygems' #require 'gearman' require '../lib/gearman' Gearman::Util.debug = true servers = ['localhost:4730', 'localhost:4731'] client = Gearman::Client.new(servers) taskset = Gearman::TaskSet.new(client) task = Gearman::Task.new('sleep', 20) task.on_complete {|d| puts d } taskset.add_task(task) taskset.wait(100)
Version data entries
9 entries across 9 versions & 2 rubygems