I see that SQS FIFO queues were recently added as a Lambda event source.
I'm trying to understand how FIFO messages with the MessageGroupId
parameter specified will be handled by Lambda.
From the boto3 SQS docs -
Messages that belong to the same message group are processed in a FIFO manner (however, messages in different message groups might be processed out of order). To interleave multiple ordered streams within a single queue, use MessageGroupId values (for example, session data for multiple users). In this scenario, multiple consumers can process the queue, but the session data of each user is processed in a FIFO fashion.
The FIFO behaviour, coupled with the phrase "interleave multiple orders streams within a single queue", suggests to me that messages with a specific MessageGroupId
will be handled by Lambda with a concurrency of one (ie no parallelisation because of FIFO), but that you will get concurrent Lambda execution across different MessageGroupId
values.
Is this a correct interpretation ?