FIFO (First-In-First-Out) topics guarantee that messages are delivered in the exact order they are published.
Key Features
- Ordering preserved via Message Group ID — all messages in the same group are delivered in sequence.
- Deduplication to avoid duplicates:
- Using a Deduplication ID.
- Or Content-Based Deduplication.
- Supports both SQS Standard and SQS FIFO subscribers.
Throughput
- Same as SQS FIFO:
- 300 messages/sec (no batching).
- 3,000 messages/sec (with batching).
SNS FIFO + SQS FIFO – Fan-Out Pattern
Use when you need:
- Fan-out to multiple subscribers.
- Guaranteed ordering.
- Duplicate prevention.
Architecture
- Producer publishes to SNS FIFO Topic.
- SNS fans out messages to multiple SQS FIFO queues (e.g., Fraud Service, Shipping Service).
- Ensures reliable delivery, strict ordering, and deduplication across all subscribers.