Troubleshoot FIFO throttling issues in Amazon SQS
By default, FIFO queues support 300 transactions per second, per API action for SendMessage, ReceiveMessage, and DeleteMessage. Requests over 300 TPS get the
ThrottlingException error even if messages in the queue are available. To
mitigate this, you can use following methods:
-
Use the Amazon SQS API batch actions
SendMessageBatch,DeleteMessageBatch, andChangeMessageVisibilityBatchto increase the TPS limit of up to 3,000 messages per second per API action, and to reduce cost. For theReceiveMessageAPI, set theMaxNumberofMessagesparameter to receive up to ten messages per transaction. For more information, see Amazon SQS batch actions. -
For FIFO queues with high throughput, follow the recommendations to optimize partition utilization. Send messages with the same message group IDs in batches. Delete messages, or change the message visibility timeout values in batches with receipt handles from the same
ReceiveMessageAPI requests. -
Increase the number of unique
MessageGroupIdvalues. This allows for an even distribution across FIFO queue partitions. For more information, see Using the Amazon SQS message group ID.
For more information, see Why doesn't my Amazon SQS
FIFO queue return all messages or messages in other message groups?