mirror of
https://github.com/avatao-content/baseimage-tutorial-framework
synced 2024-11-22 18:21:31 +00:00
Implement generating single messages from a queue
This commit is contained in:
parent
d2084b2e51
commit
9c20e94dd8
@ -44,3 +44,11 @@ class MessageSender:
|
||||
'key': self.queue_key,
|
||||
'data': data
|
||||
})
|
||||
|
||||
@staticmethod
|
||||
def generate_messages_from_queue(queue_messsge):
|
||||
for message in queue_messsge['data']['messages']:
|
||||
yield {
|
||||
'key': 'message',
|
||||
'data': message
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user