Method: Propono::Client#drain_queue
- Defined in:
- lib/propono/components/client.rb
#drain_queue(topic, &message_processor) ⇒ Object
Listens on a queue and yields for each message
Calling this will enter a queue-listening loop that yields the message_processor for each messages. The loop will end when all messages have been processed.
This method will automatically create a subscription if one does not exist, so there is no need to call subscribe in addition.
93 94 95 |
# File 'lib/propono/components/client.rb', line 93 def drain_queue(topic, &) QueueListener.drain(aws_client, config, topic, &) end |