sagemaker: Support deployment guardrails for endpoints
- Dominant language
- TypeScript
- Stars
- 12.9k
- Forks
- 4.6k
- Avg merge
- 2d 3h
- Merged PRs (30d)
- 83
Description
### Describe the feature
As described in [the SageMaker `Endpoint` L2 construct RFC](https://github.com/aws/aws-cdk-rfcs/blob/master/text/0431-sagemaker-l2-endpoint.md#feature-additions):
> [Deployment Guardrails][deployment-guardrails]: By default, when updating an endpoint, SageMaker uses an all-at-once blue/green deployment strategy: a new fleet is provisioned with the new approrpriate configuration, and upon successful provisioning, the traffic is flipped and the old fleet is terminated. To augment this functionality, the `DeploymentConfig` attribute was added to the Endpoint resource which now allows (1) the specification of a CloudWatch alarm for auto-rollback and (2) additional deployment policies beyond all-at-once, including canary and linear deployment strategies (along with more fine-grained timing settings).
[deployment-guardrails]: https://aws.amazon.com/about-aws/whats-new/2021/11/new-deployment-guardrails-amazon-sagemaker-inference-endpoints/
**Please 👍 this issue to help with the prioritization of this feature.**
### Use Case
Customers will use this feature to (1) enable auto-rollback of endpoint deployments based on CloudWatch alarms and (2) control the deployment strategy (e.g., canary, linear).
### Proposed Solution
As described in [the SageMaker `Endpoint` L2 construct RFC](https://github.com/aws/aws-cdk-rfcs/blob/master/text/0431-sagemaker-l2-endpoint.md#feature-additions):
> Adding this functionlity should consist of incorporating new attribute(s) on the Endpoint L2 construct's props interface and plumbing it through to the underlying L1 resource definition. This work should also include support for the `RetainDeploymentConfig` boolean flag which controls whether to reuse the previous deployment configuration or use the new one. Note, there are a number of [SageMaker features which prevent the use of deployment configuration][deployment-guardrails-exclusions], so defending against combinations of features may improve the customer experience with the Endpoint construct.
[deployment-guardrails-exclusions]: https://docs.aws.amazon.com/sagemaker/latest/dg/deployment-guardrails-exclusions.html
### Other Information
_No response_
### Acknowledgements
- [ ] I _may_ be able to implement this feature request
- [ ] This feature might incur a breaking change
### CDK version used
2.54.0-alpha.0
### Environment details (OS name and version, etc.)
macOS Ventura
Contributor guide
Research direction
Start with the deployment guardrails section of the SageMaker Endpoint L2 construct RFC, then inspect the Endpoint L2 props and the underlying L1 resource definition. Add support for deployment configuration, RetainDeploymentConfig, and the relevant guardrail options; done means these settings are exposed and correctly passed through, with incompatible feature combinations considered.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, typescript
- Domain
- cloud, infrastructure
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100