Class: RosettaQueue::Gateway::AmqpEventedAdapter
- Inherits:
-
Amqp
- Object
- BaseAdapter
- Amqp
- RosettaQueue::Gateway::AmqpEventedAdapter
- Defined in:
- lib/rosetta_queue/adapters/amqp.rb
Instance Method Summary collapse
Methods inherited from Amqp
#delete, #disconnect, #initialize, #receive_once, #receive_with, #send_message, #unsubscribe
Constructor Details
This class inherits a constructor from RosettaQueue::Gateway::Amqp
Instance Method Details
#exchange_strategy_for(destination, options) ⇒ Object
52 53 54 55 56 57 58 59 60 61 62 63 |
# File 'lib/rosetta_queue/adapters/amqp.rb', line 52 def exchange_strategy_for(destination, ) case destination when /^fanout\./ @exchange ||= EventedExchange::FanoutExchange.new(@adapter_settings, ) when /^topic\./ raise "Sorry. RosettaQueue can not process AMQP topics yet" when /^queue\./ @exchange ||= EventedExchange::DirectExchange.new(@adapter_settings, ) else @exchange ||= EventedExchange::DirectExchange.new(@adapter_settings, ) end end |