...
Once the deploy execution completed we can see that new function version is published and 20% of traffic will shift to this newly published version 21 ( Green deployment ) and remaining 80% will shift to old, stable version 20 . ( Blue deployment ).
...
...
API Gateway to create API and verify Blue/Green Deployment
Amazon API Gateway is a fully managed service that makes it easy for developers to create, publish, maintain, monitor, and secure APIs at any scale. APIs act as the "front door" for applications to access data, business logic, or functionality from our backend services. Using API Gateway, we can create RESTful APIs and WebSocket. We can create a web API with an HTTP endpoint for our Lambda function by using Amazon API Gateway. API Gateway provides tools for creating and documenting web APIs that route HTTP requests to Lambda functions. Resources in our API define one or more methods, such as GET or POST. Methods have an integration that routes requests to a Lambda function or another integration type. We are going to use Prod Alias to configure with API Gateway.
To create the API Gateway go to the AWS console
Navigate to the Services
Select Networking & Content Delivery from the left-hand pane
Now click on the API Gateway service option
...