Amazon ECS now enables you to define weekly event windows for scheduling task retirements on AWS Fargate
Amazon ECS now enables you to define weekly event windows for scheduling task retirements on AWS Fargate. This capability provides precise control over when infrastructure updates and task replacements occur, helping prevent disruption to mission-critical workloads during peak business hours.
AWS Fargate is a serverless, pay-as-you-go compute engine that lets you focus on building applications without managing servers. As part of the AWS shared responsibility model, Fargate maintains the underlying infrastructure with periodic platform updates. Fargate automatically retires your tasks for these updates and notifies you about upcoming task retirements via email and the AWS Health Dashboard. By default, tasks are retired 7 days after notification, but you can configure the fargateTaskRetirementWaitPeriod account setting to extend the retirement period to 14 days or initiate immediate retirement (0 days). Previously, you could build automation using the task retirement notification and wait period to perform service updates or task replacements on your own cadence. With today's launch, you can now use the Amazon EC2 event windows interface to define weekly event windows for precise control over the timing of Fargate task retirements. For example, you can schedule task retirements for a mission-critical service that requires high uptime during weekdays by configuring retirements to occur only on weekends.
To get started, configure the AWS account setting fargateEventWindows to enabled as a one-time set up. Once enabled, configure Amazon EC2 event window(s) by specifying time ranges, and associate the event window(s) with your ECS tasks by selecting Amazon ECS-managed tags as the association target. Use the aws:ecs:clusterArn tag for targeting your tasks in an ECS cluster, aws:ecs:serviceArn tag for ECS services, or aws:ecs:fargateTask with a value of true to apply the window to all Fargate tasks. This feature is now available in all commercial AWS Regions. To learn more, visit our documentation.