Class: Liebre::Actor::Consumer::Resources::Config
- Inherits:
-
Object
- Object
- Liebre::Actor::Consumer::Resources::Config
- Defined in:
- lib/liebre/actor/consumer/resources/config.rb
Instance Method Summary collapse
- #bind ⇒ Object
- #dead_exchange ⇒ Object
- #dead_queue ⇒ Object
- #exchange ⇒ Object
-
#initialize(spec) ⇒ Config
constructor
A new instance of Config.
- #queue ⇒ Object
Constructor Details
#initialize(spec) ⇒ Config
Returns a new instance of Config.
7 8 9 |
# File 'lib/liebre/actor/consumer/resources/config.rb', line 7 def initialize spec @spec = spec end |
Instance Method Details
#bind ⇒ Object
19 20 21 |
# File 'lib/liebre/actor/consumer/resources/config.rb', line 19 def bind spec.fetch(:bind, {}) end |
#dead_exchange ⇒ Object
28 29 30 31 32 |
# File 'lib/liebre/actor/consumer/resources/config.rb', line 28 def dead_exchange {:name => error_name, :type => "fanout", :opts => raw_exchange.fetch(:opts, {})} end |
#dead_queue ⇒ Object
23 24 25 26 |
# File 'lib/liebre/actor/consumer/resources/config.rb', line 23 def dead_queue {:name => error_name, :opts => raw_queue.fetch(:opts, {})} end |
#exchange ⇒ Object
15 16 17 |
# File 'lib/liebre/actor/consumer/resources/config.rb', line 15 def exchange raw_exchange end |
#queue ⇒ Object
11 12 13 |
# File 'lib/liebre/actor/consumer/resources/config.rb', line 11 def queue raw_queue.merge(:opts => dead_letter_opts) end |