simpler_workflow 0.1.4 → 0.1.5

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,13 @@
1
+ require 'aws/simple_workflow/decision_task'
2
+
3
+ module AWS
4
+ class SimpleWorkflow
5
+ module DecisionTaskAdditions
6
+ def scheduled_event(event)
7
+ @scheduled_event ||= events.to_a[event.attributes.scheduled_event_id - 1]
8
+ end
9
+ end
10
+
11
+ DecisionTask.__send__(:include, DecisionTaskAdditions)
12
+ end
13
+ end
@@ -1,3 +1,3 @@
1
1
  module SimplerWorkflow
2
- VERSION = "0.1.4"
2
+ VERSION = "0.1.5"
3
3
  end
@@ -159,7 +159,7 @@ module SimplerWorkflow
159
159
  end
160
160
 
161
161
  def scheduled_event(decision_task, event)
162
- decision_task.events.to_a[event.attributes.scheduled_event_id - 1]
162
+ decision_task.scheduled_event(event)
163
163
  end
164
164
 
165
165
  def last_activity(decision_task, event)
@@ -1,4 +1,5 @@
1
1
  require 'aws-sdk'
2
+ require 'aws/simple_workflow/decision_task_additions'
2
3
  require 'map'
3
4
 
4
5
  module SimplerWorkflow
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: simpler_workflow
3
3
  version: !ruby/object:Gem::Version
4
- hash: 19
4
+ hash: 17
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 1
9
- - 4
10
- version: 0.1.4
9
+ - 5
10
+ version: 0.1.5
11
11
  platform: ruby
12
12
  authors:
13
13
  - Frederic Jean
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2012-07-05 00:00:00 Z
18
+ date: 2012-07-06 00:00:00 Z
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency
21
21
  name: aws-sdk
@@ -107,6 +107,7 @@ files:
107
107
  - README.md
108
108
  - Rakefile
109
109
  - ext/mkrf_conf.rb
110
+ - lib/aws/simple_workflow/decision_task_additions.rb
110
111
  - lib/simpler_workflow.rb
111
112
  - lib/simpler_workflow/activity.rb
112
113
  - lib/simpler_workflow/domain.rb