shoryuken-later 0.0.5.1 → 0.0.5.2

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,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- YWVkNjJiZGRhODQ5MzgzYjg1MzBlZjYyNjJiMDQ0MGNkZmMzOWM2NA==
4
+ MGNlYzJmMTg4NTJlNDIwNTA5YjQwZjZmYjZlZTRkMTkyMzVmMGNiYQ==
5
5
  data.tar.gz: !binary |-
6
- NTAzYjFmN2UzNzg1MDMyNmZiNzY0OWI5NjdmNDRhMWQyY2M5MGQ1MA==
6
+ NDczOWYzNmM5ZjAyY2ZjYWRiNTdjMTA3M2ZmZTFmODYzYTU1NDQ4Ng==
7
7
  !binary "U0hBNTEy":
8
8
  metadata.gz: !binary |-
9
- MjFmNDMzMjE1NjIxYTAwMWNiOGUxYWIwOWRhNDQ3YjQ1YTYyM2M5ZjI5ODI5
10
- Yzk2YTM4YTk3Y2JhZGUwNWE2NjExODY0YTBiOTI3NjE0YTIxYTUzNDNjNWU3
11
- NjQ5ZTJmNTEyMTRiNzE1YmIxY2I5ZjJhODMzYmVlYTMwOWI0YTU=
9
+ ZjE0NDQwZDZhZWViMzhkYThmZTY1YjY2MDY4MDMyZTZkY2QyZmM0MDIzOTky
10
+ ZDI4ZDg0YjhiYWE4NDY4YTNmZDgwYWY2YzZjOWVjM2E3ZTg5ZTQxZjljNzM4
11
+ Y2JkNTVmZDZhNDNlMTc1YTEwMGJmNzE5YjBhOGNmNWUzZThjNWY=
12
12
  data.tar.gz: !binary |-
13
- YWZjYzAzYzQzY2YyMmI4MTBiZTc5YzczYmRlMmIzMWFlODExMjNiNzhmZmIz
14
- NjIwMGQ4OGEzMDBiMjQyZDk4NzYwNDhhNTQ4NmFhMThjOGU3ZDE2NmZkMDVm
15
- ODM5YjFlZDhjOWUyZjE5OWE4YTFhMzE1OWI3MzAwN2U0Y2M5MDE=
13
+ YjlhOTE1ZWZjYTAxYjljNjJkMDZhMDkzNjk2N2EwN2VkODU5ZmUwNDkxNjUx
14
+ NWFmMzI3Y2JkY2UyNDA0MWEwYzMyNDE2OGM0ZTcxMjU5NDdiOTkwODkyOTc5
15
+ ZjhmODZiMTlkYzU2YWY4MTIwNDJlYWYyYjQ0MGMwMmI5OGU1N2I=
data/README.md CHANGED
@@ -47,12 +47,12 @@ aws:
47
47
  # This key is only used by Shoryuken::Later
48
48
  later:
49
49
  delay: 5 * 60 # How frequently to poll the schedule table, in seconds.
50
+ pidfile: some/path/to/file.pid
50
51
  tables:
51
52
  - table1
52
53
 
53
54
  # These keys are used by both Shoryuken and Shoryuken::Later
54
55
  logfile: some/path/to/file.log
55
- pidfile: some/path/to/file.pid
56
56
 
57
57
  # These keys are only used by Shoryuken
58
58
  concurrency: 3
File without changes
@@ -117,7 +117,7 @@ module Shoryuken
117
117
  end
118
118
 
119
119
  def write_pid
120
- if path = Shoryuken::Later.options[:pidfile]
120
+ if path = Shoryuken::Later.options[:later][:pidfile]
121
121
  File.open(path, 'w') do |f|
122
122
  f.puts Process.pid
123
123
  end
@@ -125,7 +125,7 @@ module Shoryuken
125
125
  end
126
126
 
127
127
  def parse_options(argv)
128
- opts = {}
128
+ opts = {later: {}}
129
129
 
130
130
  @parser = OptionParser.new do |o|
131
131
  o.on '-d', '--daemon', 'Daemonize process' do |arg|
@@ -153,7 +153,7 @@ module Shoryuken
153
153
  end
154
154
 
155
155
  o.on '-P', '--pidfile PATH', 'Path to pidfile' do |arg|
156
- opts[:pidfile] = arg
156
+ opts[:later][:pidfile] = arg
157
157
  end
158
158
 
159
159
  o.on '-v', '--verbose', 'Print more verbose output' do |arg|
@@ -215,8 +215,10 @@ module Shoryuken
215
215
 
216
216
  config = options[:config_file] ? parse_config(options[:config_file]).deep_symbolize_keys : {}
217
217
 
218
+ Shoryuken::Later.options[:later].merge!(config.delete(:later))
218
219
  Shoryuken::Later.options.merge!(config)
219
220
 
221
+ Shoryuken::Later.options[:later].merge!(options.delete(:later))
220
222
  Shoryuken::Later.options.merge!(options)
221
223
 
222
224
  # Tables from command line options take precedence...
@@ -1,5 +1,5 @@
1
1
  module Shoryuken
2
2
  module Later
3
- VERSION = '0.0.5.1'
3
+ VERSION = '0.0.5.2'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: shoryuken-later
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.5.1
4
+ version: 0.0.5.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Joe Khoobyar
@@ -159,4 +159,3 @@ test_files:
159
159
  - spec/shoryuken/later/poller_spec.rb
160
160
  - spec/shoryuken/worker_spec.rb
161
161
  - spec/spec_helper.rb
162
- has_rdoc: