worker_roulette 0.0.8 → 0.0.9

Sign up to get free protection for your applications and to get access to all the features.
@@ -15,11 +15,11 @@ module WorkerRoulette
15
15
  end
16
16
 
17
17
  def sender_key
18
- @sender_key ||= "#{@namespace + ':' if @namespace}#{@sender}"
18
+ @sender_key = "#{@namespace + ':' if @namespace}#{@sender}"
19
19
  end
20
20
 
21
21
  def counter_key
22
- @counter_key ||= "#{@namespace + ':' if @namespace}#{COUNTER_KEY}"
22
+ @counter_key = "#{@namespace + ':' if @namespace}#{COUNTER_KEY}"
23
23
  end
24
24
 
25
25
  def enqueue_work_order_without_headers(work_order, &callback)
@@ -1,3 +1,3 @@
1
1
  module WorkerRoulette
2
- VERSION = "0.0.8"
2
+ VERSION = "0.0.9"
3
3
  end
@@ -196,6 +196,14 @@ describe WorkerRoulette do
196
196
  EM::Hiredis::PubsubClient.any_instance.should_receive(:close_connection).and_call_original
197
197
  foreman.enqueue_work_order(work_orders)
198
198
  end
199
+
200
+ it "should periodically (random time between 10 and 15 seconds?) poll the job board for new work, in case it missed a notification"
201
+ it "should not delete the messages from the queue until they have been processed succcesfully"
202
+ end
203
+
204
+ context "Read Lock" do
205
+ it "should checkout a readlock for a queue and put it back when its done processing; lock should expire after 5 minutes?"
206
+ it "should retry doing work on a queue 3 times if it is locked (ex backoff)"
199
207
  end
200
208
 
201
209
  context "Failure" do
@@ -204,10 +212,6 @@ describe WorkerRoulette do
204
212
 
205
213
  context "Concurrent Access" do
206
214
  it "should not leak connections"
207
- it "should checkout a readlock for a queue and put it back when its done processing; lock should expire after 5 minutes?"
208
- it "should retry doing work on a queue 3 times if it is locked (ex backoff)"
209
- it "should not delete the messages from the queue until they have been processed succcesfully"
210
- it "should periodically (10 seconds?) poll the job board for new work"
211
215
 
212
216
  it "should be fork() proof" do
213
217
  @subject = WorkerRoulette.a_tradesman
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: worker_roulette
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.8
4
+ version: 0.0.9
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: