How it works
Amazon SNS is a publish/subscribe service that distributes messages through topics. A publisher sends a message to a topic and SNS attempts to push copies to matching subscriptions, such as SQS queues or Lambda functions. A subscription can use a filter policy to receive relevant messages. Retries and failure handling depend on the endpoint type and configuration.
When to use it
Send one event to many receivers (fan-out), notifications by email, SMS or mobile push.
Real-world example
An online store publishes an order-completed event to an SNS topic. Subscriptions deliver copies to an inventory queue and a notification handler, allowing downstream components to process the event independently.
Key facts
- Up to 12,500,000 subscriptions per topic and 100,000 topics.
- Subscribers: SQS, Lambda, Data Firehose, HTTP(S), email, SMS, mobile.
- Filter policies route messages per subscription; FIFO topics add ordering and deduplication.
- SNS retries eligible failed deliveries and can use dead-letter queues.
Common pitfall
Do not treat SNS as a queue that retains messages indefinitely for offline subscribers. SNS retries according to endpoint type and can use a dead-letter queue; delivery failures still need handling.
Often confused with
SQS stores messages for consumers to pull; SNS pushes to subscriptions and handles delivery retries.
References
Prepared by Cloud Quest. Check current behavior and limits in the AWS documentation:
Keywords you will see in SAA-C03 questions
- notify multiple
Understand it for real with 3D models and simulated labs
Connect the concept to a working architecture.