skyrunner 0.0.12 → 0.0.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a5b9f398fbabcdd1cfcd040fb70aa64d3a3d1f90
4
- data.tar.gz: 5fe9cd8ef0e0cce01d771f5b51d2027272448566
3
+ metadata.gz: acab7006b6eec4ef27bb95523a7731881a2c137a
4
+ data.tar.gz: b6d2dafafa9aa2c779c4ae5023720e32756924c0
5
5
  SHA512:
6
- metadata.gz: 2e9d668cbc228c57033d55d7d039a1484336e7f39f16723030fdd7a661229ff595c49f33341c272630a786ce7ece1abe0137b53b354808079908fd84b2df71a1
7
- data.tar.gz: 112e3e45a72880d6d0c6537aabcbac8d6713511d0946c81bedba0f2d2183601ef34ba812e713168f4896dcbabe554e613a7113704167a1a3d215fce43700c4b4
6
+ metadata.gz: 33db221875b2e2fb7f195ce792b96a6acb0405a2caa61f138c46cb29b66e67756eb54f26c3d59f207f1ce02518712aae4ec6266ced4f506b06fbabb4ce70596e
7
+ data.tar.gz: 2759e97bb2315a1f7307706524fa3ff87dd265acf498138d3085c22492c84eff062ea440112bd2f6fccd689dc1272434fd84a5170598e28e1d6715a893016061
data/README.md CHANGED
@@ -31,7 +31,7 @@ To start a consumer
31
31
  bundle exec rake skyrunner:consume
32
32
  ``
33
33
 
34
- To shut down a consumer, send it SIGINT or SIGTERM.
34
+ To gracefully shut down a consumer, send it SIGINT or SIGTERM. It will finish up processing the messages it has de-queued before terminating.
35
35
 
36
36
  See `jobs/example_job.rb` for an example job. To run a job, just call `execute!` on the job, passing any named job arguments you want. The job class should implement the method `run`. This method will get passed the job arguments. For each task you want consumers to run, `run` should yield an array of two elements, the first being the name of the method on the job class to run for the task, and the second a Hash of method arguments.
37
37
 
@@ -1,3 +1,3 @@
1
1
  module Skyrunner
2
- VERSION = "0.0.12"
2
+ VERSION = "0.0.13"
3
3
  end
data/lib/skyrunner.rb CHANGED
@@ -83,11 +83,7 @@ module SkyRunner
83
83
  failed = false
84
84
 
85
85
  table.batch_get(:all, received_messages.map { |m| m[1]["job_id"] }.uniq, consistent_read: true) do |record|
86
- break if stop_consuming
87
-
88
86
  received_messages.select { |m| m[1]["job_id"] == record["job_id"] }.each_with_index do |received_message|
89
- break if stop_consuming
90
-
91
87
  message = received_message[1]
92
88
  job_id = message["job_id"]
93
89
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: skyrunner
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.12
4
+ version: 0.0.13
5
5
  platform: ruby
6
6
  authors:
7
7
  - Greg Fodor