simple_worker 2.0.9 → 2.0.10

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION.yml ADDED
@@ -0,0 +1,5 @@
1
+ ---
2
+ :major: 2
3
+ :minor: 0
4
+ :patch: 10
5
+ :build:
@@ -44,6 +44,7 @@ module SimpleWorker
44
44
  if File.exists?(md5_f)
45
45
  existing_md5 = IO.read(md5_f)
46
46
  end
47
+
47
48
  # Check for code changes.
48
49
  md5 = Digest::MD5.hexdigest(File.read(filename))
49
50
  new_code = false
@@ -87,7 +88,7 @@ module SimpleWorker
87
88
  #puts "Searching for #{gem_name}..."
88
89
  gems= Gem::Specification.respond_to?(:each) ? Gem::Specification.find_all_by_name(gem_name) : Gem::GemPathSearcher.new.find_all(gem_name)
89
90
  if (!Gem::GemPathSearcher.private_instance_methods.include?(:_deprecated_initialize)) && (!gems || gems.empty?)
90
- gems = Gem::GemPathSearcher.new.init_gemspecs.select { |gem| gem.name==gem_name }
91
+ gems = Gem::GemPathSearcher.new.init_gemspecs.select { |gem| gem.name==gem_name }
91
92
  end
92
93
  SimpleWorker.logger.debug 'gems found=' + gems.inspect
93
94
  gems = gems.select { |g| g.version.version==gem_info[:version] } if gem_info[:version]
@@ -151,7 +152,7 @@ ARGV.each do |arg|
151
152
  end
152
153
  require 'json'
153
154
  ")
154
- # require merged gems
155
+ # require merged gems
155
156
  merged_gems.each_pair do |k, gem|
156
157
  SimpleWorker.logger.debug "Bundling gem #{gem[:name]}..."
157
158
  f.write "$LOAD_PATH << File.join(File.dirname(__FILE__), '/gems/#{gem[:name]}/lib')\n"
@@ -168,14 +169,14 @@ require 'json'
168
169
  end
169
170
  end
170
171
 
171
- File.open(File.join(File.dirname(__FILE__), 'server', 'overrides.rb'), 'r') do |fr|
172
+ File.open(File.join(File.dirname(__FILE__), 'server', 'overrides.rb'), 'r') do |fr|
172
173
  while line = fr.gets
173
174
  f.write line
174
175
  end
175
176
  end
176
177
 
177
178
  # Now we must disable queuing while loading up classes. This is from the overrides.rb file
178
- f.write("
179
+ f.write("
179
180
  SimpleWorker.disable_queueing()
180
181
  ")
181
182
 
@@ -498,21 +499,21 @@ end
498
499
 
499
500
  def get_codes(options={})
500
501
  hash_to_send = {}
501
- uri = "projects/" + get_project_id(options) + "/codes/"
502
+ uri = "projects/" + get_project_id(options) + "/codes"
502
503
  ret = get(uri, hash_to_send)
503
504
  ret
504
505
  end
505
506
 
506
507
  def get_schedules(options={})
507
508
  hash_to_send = {}
508
- uri = "projects/" + get_project_id(options) + "/schedules/"
509
+ uri = "projects/" + get_project_id(options) + "/schedules"
509
510
  ret = get(uri, hash_to_send)
510
511
  ret
511
512
  end
512
513
 
513
514
  def get_jobs(options={})
514
515
  hash_to_send = {}
515
- uri = "projects/" + get_project_id(options) + "/tasks/"
516
+ uri = "projects/" + get_project_id(options) + "/tasks"
516
517
  ret = get(uri, hash_to_send)
517
518
  ret
518
519
  end
data/lib/simple_worker.rb CHANGED
@@ -1,3 +1,5 @@
1
+ puts 'WARNING: The simple_worker gem is deprecated! Please use iron_worker gem instead: https://github.com/iron-io/iron_worker_ruby. Same gem, different name.'
2
+
1
3
  require_relative 'simple_worker/utils'
2
4
  require_relative 'simple_worker/service'
3
5
  require_relative 'simple_worker/base'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: simple_worker
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.9
4
+ version: 2.0.10
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,11 +9,11 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2011-11-24 00:00:00.000000000 Z
12
+ date: 2011-12-20 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: zip
16
- requirement: &11412580 !ruby/object:Gem::Requirement
16
+ requirement: &24535980 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ! '>='
@@ -21,10 +21,10 @@ dependencies:
21
21
  version: '0'
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *11412580
24
+ version_requirements: *24535980
25
25
  - !ruby/object:Gem::Dependency
26
26
  name: rest-client
27
- requirement: &11436900 !ruby/object:Gem::Requirement
27
+ requirement: &24550760 !ruby/object:Gem::Requirement
28
28
  none: false
29
29
  requirements:
30
30
  - - ! '>='
@@ -32,10 +32,10 @@ dependencies:
32
32
  version: '0'
33
33
  type: :runtime
34
34
  prerelease: false
35
- version_requirements: *11436900
35
+ version_requirements: *24550760
36
36
  - !ruby/object:Gem::Dependency
37
37
  name: zip
38
- requirement: &11435060 !ruby/object:Gem::Requirement
38
+ requirement: &24550020 !ruby/object:Gem::Requirement
39
39
  none: false
40
40
  requirements:
41
41
  - - ! '>='
@@ -43,10 +43,10 @@ dependencies:
43
43
  version: '0'
44
44
  type: :runtime
45
45
  prerelease: false
46
- version_requirements: *11435060
46
+ version_requirements: *24550020
47
47
  - !ruby/object:Gem::Dependency
48
48
  name: rest-client
49
- requirement: &11433880 !ruby/object:Gem::Requirement
49
+ requirement: &24548960 !ruby/object:Gem::Requirement
50
50
  none: false
51
51
  requirements:
52
52
  - - ! '>='
@@ -54,7 +54,7 @@ dependencies:
54
54
  version: '0'
55
55
  type: :runtime
56
56
  prerelease: false
57
- version_requirements: *11433880
57
+ version_requirements: *24548960
58
58
  description: The official SimpleWorker gem for http://www.simpleworker.com
59
59
  email: travis@appoxy.com
60
60
  executables: []
@@ -62,6 +62,7 @@ extensions: []
62
62
  extra_rdoc_files:
63
63
  - README.markdown
64
64
  files:
65
+ - VERSION.yml
65
66
  - lib/generators/simple_worker/simple_worker_generator.rb
66
67
  - lib/simple_worker.rb
67
68
  - lib/simple_worker/api.rb