Posted On: Aug 1, 2023

Starting today, you can use Amazon CloudWatch alarms to trigger an instance refresh rollback. EC2 Auto Scaling’s instance refresh allows you to perform a rolling replacement of instances in an Auto Scaling group, and instance refresh rollback can undo changes an instance refresh made if the instance refresh cannot complete as desired. With this launch, you can configure Auto Scaling to monitor CloudWatch alarms during an instance refresh, and automatically revert any changes made if the alarms are triggered.

Through this new capability, you can use alarms on default or custom CloudWatch metrics to ensure the successful deployment of new instances to your Auto Scaling group. Auto Scaling will cancel an instance refresh and initiate a rollback if the alarms you specified breach. You can choose to trigger rollbacks based on either individual metric or composite CloudWatch alarms. Examples: you can now monitor your Auto Scaling group for conditions such as average CPU utilization breaching 65% threshold or application latency increasing beyond 300ms during an instance refresh, and trigger a rollback.

Instance refresh rollback support for CloudWatch alarms is available in all AWS regions, including the AWS GovCloud (US) Regions. This feature is available through the AWS Management Console, AWS SDKs, and the AWS Command Line Interface. AWS CloudFormation support will be coming soon.

To learn more about instance refresh and instance refresh rollbacks, please visit these product pages: instance refresh and instance refresh rollbacks.