Home › Forums › AWS › AWS Certified Solutions Architect Associate › blue green deployment environment need to be provisioned and maintained?
-
blue green deployment environment need to be provisioned and maintained?
Nikee-TutorialsDojo updated 1 week, 1 day ago 2 Members · 2 Posts
-
An e-commerce company uses a regional Amazon API Gateway to host its public REST APIs. The API Gateway endpoint is accessed through a custom domain name configured using an Amazon Route 53 alias record. As part of its continuous improvement efforts, the company wants to release a new version of its APIs which includes enhanced features and performance optimizations.
How can the company minimize customer impact, and ensure MINIMAL data loss during the update process in the MOST cost-effective manner?
– Implement a canary release deployment strategy for the API Gateway. Deploy the latest version of the APIs to a canary stage and direct a portion of the user traffic to this stage. Verify the new APIs. Gradually increase the traffic percentage, monitor for any issues, and, if successful, promote the canary stage to production.– Create a new API Gateway with the updated version of the APIs in OpenAPI JSON or YAML file format, but keep the same custom domain name for the new API Gateway
– Modify the existing API Gateway with the updated version of the APIs, but keep the same custom domain name for the new API Gateway by using the import-to-update operation in either overwrite or merge mode
– Implement a blue-green deployment strategy for the API Gateway. Deploy the latest version of the APIs to the green environment and direct some of the user traffic to it. Verify the new APIs. If it is thoroughly verified, deploy the green environment to production
Why explanation says:
> The option that says: Implement a blue-green deployment strategy for the API Gateway. Deploy the latest version of the APIs to the green environment and direct some of the user traffic to it. Verify the new APIs. If it is thoroughly verified, deploy the green environment to production is incorrect. In a blue-green deployment, the blue (existing) and green (updated) environments must be provisioned and maintained. This adds complexity and cost to the update process, which breaks the cost requirement that’s explicitly mentioned in the scenario. Additionally, directing some user traffic to the green environment may lead to issues for those users, especially if there are undiscovered bugs or performance problems in the updated APIs.
Why we need to provisioned and maintain env for blue/green deployment but not the case for canary deployment? In fact I think the only different between canary and blue/green deployment is whether or not we expose the new prod deployment to user or not right?
Thankyou!
-
Hello odemsy,
Thank you for your insightful question! I appreciate the opportunity to clarify why canary release deployment is the most appropriate strategy in this scenario.
The key difference between canary and blue/green deployments lies in how resources are provisioned and how traffic is gradually directed to the new API version.
In a blue/green deployment, two environments (the “blue” environment, which is the current version, and the “green” environment, which is the new version) are provisioned and maintained simultaneously. This approach requires duplicating resources for both environments, which can increase costs due to maintaining two parallel environments for the duration of the deployment process. The traffic is then switched from the blue environment to the green environment once the green environment is verified and fully ready for production. While this provides good isolation and testing, additional environment provisioning and maintenance can be resource-intensive and costly.
On the other hand, in a canary deployment, you don’t need to provision a whole new set of resources. Instead, you deploy the new API version to a small subset of users and gradually increase the traffic to the new version as it proves stable. This allows you to minimize the risk of issues affecting many users and doesn’t require maintaining separate full-scale environments. The cost is lower, and you only adjust traffic distribution within a single environment, not duplicating the entire infrastructure.
To address your point, while both deployment strategies involve controlling the exposure of the new version to users, the canary deployment allows for a more gradual and controlled rollout without the need to fully replicate environments. It offers a way to test and verify the new version with a small user base before scaling up, making it cost-effective and easier to manage.
I hope this helps clarify any confusion you might have. Please feel free to ask if you have any further questions!
Regards,
Nikee @ Tutorials Dojo
Log in to reply.