1 Answer
- Newest
- Most votes
- Most comments
0
Hi,
The public doc answers your question: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/FIFO-queues-understanding-logic.html
If the consumer detects a failed ReceiveMessage action, it can retry as many times
as necessary, using the same receive request attempt ID. Assuming that the consumer
receives at least one acknowledgement before the visibility timeout expires, multiple retries don't
affect the ordering of messages.
If you carefully re-use the attempt ID, the ordering of messages is not affected, i.e it is preserved.
Best,
Didier
Relevant content
- asked 3 years ago
- Accepted Answerasked 9 months ago
- AWS OFFICIALUpdated 4 months ago
- AWS OFFICIALUpdated a year ago
- AWS OFFICIALUpdated a year ago
- AWS OFFICIALUpdated 2 months ago
Thanks Didier for the doc. The concern is more of sending message failure from SNS to SQS. In the doc link you shared, it says multiple retries don't effect ordering
https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/FIFO-queues-understanding-logic.html#:~:text=If%20the%20producer,nor%20introduce%20duplicates.
So question is in case of Any message failure from SNS to SQS (Both using fifo topic and queue), retry will happen. will retry pauses other messages , so the messages order remain intact? or will the sqs rearrange retried messages based on sequence id to maintain order? or the order wont remain intact in this case?
Note: it is safe to assume all messages have same message groupId