Class: Freddy::Adapters::BunnyAdapter::Queue
- Inherits:
-
Shared::Queue
- Object
- Shared::Queue
- Freddy::Adapters::BunnyAdapter::Queue
- Defined in:
- lib/freddy/adapters/bunny_adapter.rb
Instance Method Summary collapse
Methods inherited from Shared::Queue
Constructor Details
This class inherits a constructor from Freddy::Adapters::Shared::Queue
Instance Method Details
#subscribe(&block) ⇒ Object
49 50 51 52 53 54 |
# File 'lib/freddy/adapters/bunny_adapter.rb', line 49 def subscribe(&block) @queue.subscribe do |info, properties, payload| parsed_payload = Payload.parse(payload) block.call(Delivery.new(parsed_payload, properties, info.routing_key)) end end |