Class: Bricolage::StreamingLoad::DispatcherMessage
- Inherits:
-
Bricolage::SQSMessage
- Object
- Bricolage::SQSMessage
- Bricolage::StreamingLoad::DispatcherMessage
- Defined in:
- lib/bricolage/streamingload/dispatchermessage.rb
Direct Known Subclasses
CheckPointDispatcherMessage, DispatchDispatcherMessage, FlushTableDispatcherMessage, S3ObjectDispatcherMessage, ShutdownDispatcherMessage
Constant Summary
Constants inherited from Bricolage::SQSMessage
Bricolage::SQSMessage::SQS_EVENT_SOURCE
Instance Attribute Summary
Attributes inherited from Bricolage::SQSMessage
#delay_seconds, #message_id, #name, #receipt_handle, #source, #time
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from Bricolage::SQSMessage
#body, create, for_sqs_record, for_sqs_result, get_event_time, #initialize, parse_sqs_record
Constructor Details
This class inherits a constructor from Bricolage::SQSMessage
Class Method Details
.get_concrete_class(msg, rec) ⇒ Object
10 11 12 13 14 15 16 17 18 19 |
# File 'lib/bricolage/streamingload/dispatchermessage.rb', line 10 def DispatcherMessage.get_concrete_class(msg, rec) case when rec['eventName'] == 'shutdown' then ShutdownDispatcherMessage when rec['eventName'] == 'dispatch' then DispatchDispatcherMessage when rec['eventName'] == 'flushtable' then FlushTableDispatcherMessage when rec['eventName'] == 'checkpoint' then CheckPointDispatcherMessage when !!rec['s3'] then S3ObjectDispatcherMessage else UnknownSQSMessage end end |
Instance Method Details
#data? ⇒ Boolean
25 26 27 |
# File 'lib/bricolage/streamingload/dispatchermessage.rb', line 25 def data? false end |
#message_type ⇒ Object
21 22 23 |
# File 'lib/bricolage/streamingload/dispatchermessage.rb', line 21 def raise "#{self.class}\#message_type must be implemented" end |