Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
SPDX-License-Identifier: CC-BY-SA-4.0
When you update Amazon SageMaker endpoints that have automatic scaling applied, complete the following steps:
To update an endpoint that has automatic scaling applied
Deregister the endpoint as a scalable target by calling DeregisterScalableTarget.
Because you turn off automatic scaling before you update the endpoint, you might want to take the additional precaution of increasing the number of instances for your endpoint during the update. To do this, update the instance counts for the production variants hosted at the endpoint by calling UpdateEndpointWeightsAndCapacities.
Call DescribeEndpoint repeatedly until the value of the EndpointStatus
field of the response is InService
.
Call DescribeEndpointConfig to get the values of the current endpoint config.
Create a new endpoint config by calling CreateEndpointConfig. For the InitialInstanceCount
field of each production variant, specify the corresponding value of DesiredInstanceCount
from the response to the previous call to DescribeEndpoint. For all other values, use the values that you got as the response when you called DescribeEndpointConfig in the previous step.
Update the endpoint by calling UpdateEndpoint. Specify the endpoint config you created in the previous step as the EndpointConfig
field.
Re-enable automatic scaling by calling RegisterScalableTarget.