RollingUpdateOptions Struct
Options for customizing the rolling update.
| Source | aws-autoscaling/lib/auto-scaling-group.ts |
|---|
Example
ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import * as cdk from 'aws-cdk-lib';
import { aws_autoscaling as autoscaling } from 'aws-cdk-lib';
const rollingUpdateOptions: autoscaling.RollingUpdateOptions = {
maxBatchSize: 123,
minInstancesInService: 123,
minSuccessPercentage: 123,
pauseTime: cdk.Duration.minutes(30),
suspendProcesses: [autoscaling.ScalingProcess.LAUNCH],
waitOnResourceSignals: false,
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
import aws_cdk as cdk
from aws_cdk import aws_autoscaling as autoscaling
rolling_update_options = autoscaling.RollingUpdateOptions(
max_batch_size=123,
min_instances_in_service=123,
min_success_percentage=123,
pause_time=cdk.Duration.minutes(30),
suspend_processes=[autoscaling.ScalingProcess.LAUNCH],
wait_on_resource_signals=False
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.*;
import software.amazon.awscdk.services.autoscaling.*;
RollingUpdateOptions rollingUpdateOptions = RollingUpdateOptions.builder()
.maxBatchSize(123)
.minInstancesInService(123)
.minSuccessPercentage(123)
.pauseTime(Duration.minutes(30))
.suspendProcesses(List.of(ScalingProcess.LAUNCH))
.waitOnResourceSignals(false)
.build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK;
using Amazon.CDK.AWS.AutoScaling;
var rollingUpdateOptions = new RollingUpdateOptions {
MaxBatchSize = 123,
MinInstancesInService = 123,
MinSuccessPercentage = 123,
PauseTime = Duration.Minutes(30),
SuspendProcesses = new [] { ScalingProcess.LAUNCH },
WaitOnResourceSignals = false
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import cdk "github.com/aws/aws-cdk-go/awscdk"
import "github.com/aws/aws-cdk-go/awscdk"
rollingUpdateOptions := &RollingUpdateOptions{
MaxBatchSize: jsii.Number(123),
MinInstancesInService: jsii.Number(123),
MinSuccessPercentage: jsii.Number(123),
PauseTime: cdk.Duration_Minutes(jsii.Number(30)),
SuspendProcesses: []ScalingProcess{
awscdk.Aws_autoscaling.ScalingProcess_LAUNCH,
},
WaitOnResourceSignals: jsii.Boolean(false),
}
Properties
maxBatchSizeoptionalnumbermax_batch_sizeoptionalint | floatmaxBatchSizeoptionalNumberMaxBatchSizeoptionaldoubleMaxBatchSizeoptional*float64 = 1 #The maximum number of instances that AWS CloudFormation updates at once.
This number affects the speed of the replacement.
minInstancesInServiceoptionalnumbermin_instances_in_serviceoptionalint | floatminInstancesInServiceoptionalNumberMinInstancesInServiceoptionaldoubleMinInstancesInServiceoptional*float64 = 0 #The minimum number of instances that must be in service before more instances are replaced.
This number affects the speed of the replacement.
minSuccessPercentageoptionalnumbermin_success_percentageoptionalint | floatminSuccessPercentageoptionalNumberMinSuccessPercentageoptionaldoubleMinSuccessPercentageoptional*float64 #The percentage of instances that must signal success for the update to succeed.
Default: The minSuccessPercentage configured for signals on the AutoScalingGroup
pauseTimeoptionalDurationpause_timeoptionalDurationpauseTimeoptionalDurationPauseTimeoptionalDurationPauseTimeoptionalDuration #The pause time after making a change to a batch of instances.
Default: The timeout configured for signals on the AutoScalingGroup
suspendProcessesoptionalScalingProcess[]suspend_processesoptionaltyping.List[ScalingProcess]suspendProcessesoptionalList<ScalingProcess>SuspendProcessesoptionalScalingProcess[]SuspendProcessesoptional*[]ScalingProcess #Specifies the Auto Scaling processes to suspend during a stack update.
Default: HealthCheck, ReplaceUnhealthy, AZRebalance, AlarmNotification, ScheduledActions.
Suspending processes prevents Auto Scaling from interfering with a stack update.
waitOnResourceSignalsoptionalbooleanwait_on_resource_signalsoptionalboolwaitOnResourceSignalsoptionalBooleanWaitOnResourceSignalsoptionalboolWaitOnResourceSignalsoptional*bool #Specifies whether the Auto Scaling group waits on signals from new instances during an update.
Default: true if you configured signals on the AutoScalingGroup, false otherwise