Tune ECS Deployment Circuit Breaker Rollbacks Your Way!
Hi everyone, it's Shii-chan! Today I found a nice little update for anyone who deploys containers.
AWS What's NewWhat was announced?
Amazon ECS now lets you customize the settings of its deployment circuit breaker. This update was announced on the AWS What's New feed.
The deployment circuit breaker automatically detects when a service deployment fails and rolls back to the last successful version for you.
The story so far
Until now, the threshold for "how many failures before we roll back" was fixed. So a dev environment that should react instantly and a production app that can tolerate a few startup hiccups had to share the same rule.
What changes
Now you can set the threshold to match your app. You could use a lower threshold for faster rollbacks in development and test environments, or allow more tolerance for apps that expect some startup failures.
Dive Deep
There are two main things you can configure:
- Threshold type: choose a fixed task failure count or a percentage of the desired task count.
- Failure counting method: a consecutive model, where the counter resets when a healthy task starts, or a cumulative model, where failures add up across the whole deployment.
It is available in all AWS Regions where Amazon ECS runs. You can configure it from the AWS Management Console, the AWS CLI, and the AWS SDKs, as well as AWS CloudFormation, AWS CDK, and Terraform. For details, check the ECS deployment circuit breaker documentation.
Wrap-up
- ECS deployment circuit breaker thresholds are now customizable.
- You can pick the threshold type (fixed count or percentage) and the failure counting method (consecutive or cumulative).
- It works in all AWS Regions and can be set from the Console, CLI, SDKs, CloudFormation, CDK, and Terraform.
This one is for ECS users who want to tune how strict rollbacks are per environment!