3 / 2430

Orchestrating SageMaker AI endpoint auto scaling with AWS CDK

TL;DR

Updating a SageMaker AI endpoint that has Application Auto Scaling registered makes AWS CloudFormation and AWS CDK deployments fail. This post shows how to build a reusable AWS CDK construct with CloudFormation custom resources that deregisters and re-registers auto scaling automatically, so you can update the endpoint and its scaling in a single deployment.

Nauti's Take

For small teams, this is primarily a deployment sequencing issue: first check whether your pipeline treats endpoint changes and Application Auto Scaling registration as dependent steps. The AWS construct is a useful starting point, yet the evidence here is limited to one AWS blog post, so test rollbacks, existing alarm states, and the cost impact of extra capacity before using it in production.

Sources