iron_worker_ng 0.1.11 → 0.1.12

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.1.11
1
+ 0.1.12
@@ -50,6 +50,18 @@ keys.each do |key|
50
50
  @params[key.to_sym] = @params[key]
51
51
  end
52
52
 
53
+ def payload
54
+ @payload
55
+ end
56
+
57
+ def iron_io_token
58
+ @iron_io_token
59
+ end
60
+
61
+ def iron_io_project_id
62
+ @iron_io_project_id
63
+ end
64
+
53
65
  def params
54
66
  @params
55
67
  end
@@ -66,18 +78,14 @@ end
66
78
  unless worker_class.nil?
67
79
  worker_inst = worker_class.new
68
80
 
69
- class << worker_inst
70
- attr_accessor :iron_io_token
71
- attr_accessor :iron_io_project_id
72
- attr_accessor :iron_worker_task_id
73
- attr_accessor :params
81
+ params.keys.each do |param|
82
+ if param.class == String
83
+ if worker_inst.respond_to?(param + '=')
84
+ worker_inst.send(param + '=', params[param])
85
+ end
86
+ end
74
87
  end
75
88
 
76
- worker_inst.iron_io_token = @iron_io_token
77
- worker_inst.iron_io_project_id = @iron_io_project_id
78
- worker_inst.iron_worker_task_id = @iron_worker_task_id
79
- worker_inst.params = @params
80
-
81
89
  worker_inst.run
82
90
  end
83
91
  RUNNER
@@ -50,7 +50,7 @@ module IronWorkerNG
50
50
  if @merge_gem_reqs.length > 0
51
51
  reqs = @merge_gem_reqs.map { |req| Bundler::DepProxy.new(req, Gem::Platform::RUBY) }
52
52
 
53
- souce = nil
53
+ source = nil
54
54
  begin
55
55
  source = Bundler::Source::Rubygems.new
56
56
  rescue Bundler::GemfileNotFound
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: iron_worker_ng
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.11
4
+ version: 0.1.12
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -153,7 +153,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
153
153
  version: '0'
154
154
  segments:
155
155
  - 0
156
- hash: 45984719
156
+ hash: 628654479
157
157
  required_rubygems_version: !ruby/object:Gem::Requirement
158
158
  none: false
159
159
  requirements: