Class: QProcessor::SQSMessage
- Defined in:
- lib/qprocessor/sqs_message.rb
Instance Attribute Summary
Attributes inherited from Message
Instance Method Summary collapse
-
#dispose ⇒ Object
Deletes a message from the source queue.
-
#id ⇒ Object
Retrieves the message identifier.
-
#initialize(source, client, queue_url) ⇒ SQSMessage
constructor
A new instance of SQSMessage.
Methods inherited from Message
Constructor Details
#initialize(source, client, queue_url) ⇒ SQSMessage
Returns a new instance of SQSMessage.
5 6 7 8 9 |
# File 'lib/qprocessor/sqs_message.rb', line 5 def initialize(source, client, queue_url) super(source) @client = client @queue_url = queue_url end |
Instance Method Details
#dispose ⇒ Object
Deletes a message from the source queue.
12 13 14 |
# File 'lib/qprocessor/sqs_message.rb', line 12 def dispose @client.(queue_url: @queue_url, receipt_handle: source.receipt_handle) end |
#id ⇒ Object
Retrieves the message identifier.
17 18 19 |
# File 'lib/qprocessor/sqs_message.rb', line 17 def id source. end |