Fanning-out messages is a common technique to increase the scalability of background processing tasks. It involves publishing a message which is then consumed by multiple endpoints asynchronously. In AWS this can easily be achieved by combining the Amazon Simple Notification Service (Amazon SNS) with the Amazon Simple Queue Service (Amazon SQS).
Learning how to implement a fan-out scenario will increase your ability to build scalable and resilient solutions using Amazon Web Services.
In this lab, you will create a topic and some queues, you will configure them to work with each other, and you will test the fan-out scenario.
Learning Objectives
Upon completion of this beginner lab, you will be able to:
- Create an Amazon SNS topic
- Create an Amazon SQS queue
- Subscribe your Amazon SQS queues to your Amazon SNS topic
- Use the AWS command-line interface to test the fan-out scenario
Intended Audience
- Candidates for the AWS Solutions Architect Associate certification
- Cloud Architects
- Data Engineers
- DevOps Engineers
- Software Engineers
Prerequisites
Familiarity with the following will be beneficial but is not required:
- Amazon SNS
- Amazon SQS
- AWS command-line interface
- The Bash terminal
The following courses can be used to fulfill the prerequisites:
- Using SQS, SNS and SES in a Decoupled and Distributed Environment
- How to Use the AWS Command-Line Interface
- Linux Command Line Byte Session
Updates
April 28th, 2022 - Resolved lab setup issue
January 17th, 2022 - Leverage shell variables to streamline entering commands referencing outputs of previous commands
October 23rd, 2021 - Added example of the queue URL to avoid errors when filling in the command placeholders
September 3rd, 2021 - Added note commentary on SQS queue table rendering issue
Environment before
Environment after
Andrew is a Labs Developer with previous experience in the Internet Service Provider, Audio Streaming, and CryptoCurrency industries. He has also been a DevOps Engineer and enjoys working with CI/CD and Kubernetes.
He holds multiple AWS certifications including Solutions Architect Associate and Professional.