AWS Certified Developer – Associate (DVA-C02)Development with AWS ServicesMedium

A developer is building an application that needs to publish real-time notifications to multiple subscribers over different protocols (e.g., SMS, email, HTTP/S endpoints, Lambda functions). The application should not be aware of the specific delivery mechanisms or subscriber details, promoting loose coupling. Which AWS service is best suited for this publish-subscribe messaging pattern?

  1. AAmazon SNS
  2. BAmazon Kinesis Data Streams
  3. CAmazon SQS
  4. DAmazon EventBridge
Show answer & explanation

Correct answer: A. Amazon SNS

Amazon Simple Notification Service (SNS) is a fully managed messaging service for both application-to-application (A2A) and application-to-person (A2P) communication. It enables you to send messages to a large number of subscribers simultaneously over various supported protocols, fitting the publish-subscribe pattern perfectly.

Why the other options are wrong

  • B. Amazon Kinesis Data Streams is for real-time processing of large data streams, not for general-purpose notification broadcasting across multiple protocols.
  • C. Amazon SQS is a message queuing service designed for reliable, point-to-point message delivery between systems, not for broadcasting messages to multiple subscribers over diverse protocols.
  • D. Amazon EventBridge (formerly CloudWatch Events) is an event bus service that connects application components together, but SNS is specifically designed for the broader 'publish-subscribe' notification pattern with diverse delivery protocols.

Amazon SNS

A highly available, durable, secure, and fully managed pub/sub messaging service that enables you to decouple microservices, distributed systems, and serverless applications.

  • Supports various subscription protocols (SMS, email, HTTP/S, SQS, Lambda).
  • One-to-many message delivery.
  • Decouples publishers from subscribers.

Memory trick: SNS broadcasts to all, SQS sends one-to-one.

More Development with AWS Services questions