What does this AWS Solutions Implementation do?

This solution helps buffer incoming user requests to your website during large bursts of traffic. It creates a cloud infrastructure designed to temporarily offload incoming traffic to your website, and it provides options to customize and integrate a virtual waiting room. The waiting room acts as a holding area for visitors to your website and allows traffic to pass through when there is enough capacity.

Examples of large-scale events that could produce a surge in website traffic include:

  • Start of sale for concert or sporting event tickets
  • Fire sale or other large retail sale, such as Black Friday
  • New product launch with broad marketing announcements
  • Exam access and class attendance for online testing and lessons
  • Release of medical appointment slots
  • Launch of a new direct-to-customer service that requires account creation and payments

Benefits

Structured queue
blank

Users are assigned a queue number when they enter the waiting room. They maintain their position in the queue and only leave the waiting room to enter the target site when it’s their turn.

Scalability
blank

The solution can control traffic for large-scale events. Traffic spikes won’t overwhelm your systems; keeping your website up and running for your customers.

Protect downstream systems

The solution generates signed, time-limited JSON web tokens (JWTs), which allow the downstream system's APIs to validate users have successfully gone through the waiting room before processing any requests.

Standalone integration or use with OpenID

The solution’s OpenID adapter provides a set of OIDC-compatible APIs that can be used with existing web hosting software that support OIDC identity providers.

Sample waiting room
blank

The solution provides a sample waiting room website to demonstrate a minimal end-to-end waiting room solution for customization.

AWS Solutions Implementation overview

The diagram below presents the architecture you can automatically deploy using the solution's implementation guide and accompanying AWS CloudFormation templates.

AWS Virtual Waiting Room | Architecture diagram
 Click to enlarge

AWS Virtual Waiting Room Solutions Implementation architecture

The AWS CloudFormation template deploys the following infrastructure:

1. An Amazon CloudFront distribution to deliver public API calls for the client.

2. Amazon API Gateway public API resources to process queue requests from the virtual waiting room, track the queue position, and support validation of tokens that allow access to the target website.

3. An Amazon Simple Queue Service (Amazon SQS) queue to regulate traffic to the AWS Lambda function that processes the queue messages. Instead of invoking the Lambda function for each request, the SQS queue batches the incoming bursts of requests.

4. API Gateway private API resources to support administrative functions.

5. Lambda functions to validate and process public and private API requests, and return the appropriate responses.

6. Amazon Virtual Private Cloud (VPC) to host the Lambda functions that interact directly with the Amazon ElastiCache for Redis cluster. VPC endpoints allow Lambda functions in the VPC to communicate with services within the solution.

7. An Amazon CloudWatch rule to invoke a Lambda function that works with a custom Amazon EventBridge bus to periodically broadcast status updates.

8. An Amazon DynamoDB table to store token data.

9. AWS Secrets Manager to store keys for token operations and other sensitive data.

10. (Optional) Authorizer component consisting of an AWS Identity and Access Management (IAM) role and a Lambda function to validate signatures for your API calls. The only requirement for the authorizer to protect your API is to use API Gateway.

11. (Optional) Amazon Simple Notification Service (Amazon SNS), CloudWatch, and Lambda functions to support two inlet strategies.

12. (Optional) OpenID adaptor component with API Gateway and Lambda functions to allow an OpenID provider to authenticate users to your website. CloudFront distribution with an Amazon Simple Storage Service (Amazon S3) bucket for the waiting room page for this component.

13. (Optional) A CloudFront distribution with Amazon S3 origin bucket for the optional sample waiting room web application.

AWS Virtual Waiting Room

Version 1.0.0
Released: 11/2021
Author: AWS

Estimated deployment time: 30 min

Estimated cost Source code  CloudFormation template 
Did this Solutions Implementation help you?
Provide feedback 
Build icon
Deploy a Solution yourself

Browse our library of AWS Solutions Implementations to get answers to common architectural problems.

Learn more 
Find an APN partner
Find an APN Partner

Find AWS certified consulting and technology partners to help you get started.

Learn more 
Explore icon
Explore Solutions Consulting Offers

Browse our portfolio of Consulting Offers to get AWS-vetted help with solution deployment.

Learn more