Class: Kyklos::Adapters::ShoryukenAdapter
- Inherits:
-
BaseAdapter
- Object
- BaseAdapter
- Kyklos::Adapters::ShoryukenAdapter
- Defined in:
- lib/kyklos/adapters/shoryuken_adapter.rb
Defined Under Namespace
Classes: Worker
Instance Attribute Summary collapse
-
#queue_url ⇒ Object
readonly
Returns the value of attribute queue_url.
Instance Method Summary collapse
- #assign_cloudwatchevents(job_id:, rule_name_prefix:, rule:) ⇒ Object
-
#initialize(*args) ⇒ ShoryukenAdapter
constructor
A new instance of ShoryukenAdapter.
Methods inherited from BaseAdapter
Constructor Details
#initialize(*args) ⇒ ShoryukenAdapter
Returns a new instance of ShoryukenAdapter.
30 31 32 |
# File 'lib/kyklos/adapters/shoryuken_adapter.rb', line 30 def initialize(*args) @queue_url = args[0] end |
Instance Attribute Details
#queue_url ⇒ Object (readonly)
Returns the value of attribute queue_url.
28 29 30 |
# File 'lib/kyklos/adapters/shoryuken_adapter.rb', line 28 def queue_url @queue_url end |
Instance Method Details
#assign_cloudwatchevents(job_id:, rule_name_prefix:, rule:) ⇒ Object
34 35 36 37 38 39 40 41 42 43 44 45 |
# File 'lib/kyklos/adapters/shoryuken_adapter.rb', line 34 def assign_cloudwatchevents(job_id:, rule_name_prefix:, rule:) assign_queue_policy(job_id, rule_name_prefix, rule.arn) [ { id: target_id(job_id), arn: target_arn, input: { job_id: job_id }.to_json } ] end |