Skip to content
v2.274.0

TrafficRoutingConfigProperty Struct ​

Defines the traffic routing strategy during an endpoint deployment to shift traffic from the old fleet to the new fleet.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_sagemaker as sagemaker } from 'aws-cdk-lib';
const trafficRoutingConfigProperty: sagemaker.CfnEndpoint.TrafficRoutingConfigProperty = {
  type: 'type',

  // the properties below are optional
  canarySize: {
    type: 'type',
    value: 123,
  },
  linearStepSize: {
    type: 'type',
    value: 123,
  },
  waitIntervalInSeconds: 123,
};

Properties ​

canarySizeIResolvable | CfnEndpoint.CapacitySizePropertycanary_sizetyping.Union[IResolvable, CapacitySizeProperty]canarySizeIResolvableCanarySizeIResolvableCanarySizeinterface{}#
Batch size for the first step to turn on traffic on the new endpoint fleet.

Value must be less than or equal to 50% of the variant's total instance count.

linearStepSizeIResolvable | CfnEndpoint.CapacitySizePropertylinear_step_sizetyping.Union[IResolvable, CapacitySizeProperty]linearStepSizeIResolvableLinearStepSizeIResolvableLinearStepSizeinterface{}#
Batch size for each step to turn on traffic on the new endpoint fleet.

Value must be 10-50% of the variant's total instance count.

typestringtypestrtypeStringTypestringType*stringrequired#
Traffic routing strategy type.
notes
  • ALL_AT_ONCE : Endpoint traffic shifts to the new fleet in a single step.
  • CANARY : Endpoint traffic shifts to the new fleet in two steps. The first step is the canary, which is a small portion of the traffic. The second step is the remainder of the traffic.
  • LINEAR : Endpoint traffic shifts to the new fleet in n steps of a configurable size.
waitIntervalInSecondsnumberwait_interval_in_secondsint | floatwaitIntervalInSecondsNumberWaitIntervalInSecondsdoubleWaitIntervalInSeconds*float64#
The waiting time (in seconds) between incremental steps to turn on traffic on the new endpoint fleet.