Class EcsDeploymentConfig
java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.Resource
software.amazon.awscdk.services.codedeploy.BaseDeploymentConfig
software.amazon.awscdk.services.codedeploy.EcsDeploymentConfig
- All Implemented Interfaces:
IEnvironmentAware,IResource,IBaseDeploymentConfig,IEcsDeploymentConfig,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
@Generated(value="jsii-pacmak/1.118.0 (build 02eec31)",
date="2025-11-04T09:27:36.804Z")
@Stability(Stable)
public class EcsDeploymentConfig
extends BaseDeploymentConfig
implements IEcsDeploymentConfig
A custom Deployment Configuration for an ECS Deployment Group.
Example:
FargateService service;
ITargetGroup blueTargetGroup;
ITargetGroup greenTargetGroup;
IApplicationListener listener;
IApplicationListener testListener;
EcsDeploymentGroup.Builder.create(this, "BlueGreenDG")
.autoRollback(AutoRollbackConfig.builder()
// CodeDeploy will automatically roll back if the 8-hour approval period times out and the deployment stops
.stoppedDeployment(true)
.build())
.service(service)
.blueGreenDeploymentConfig(EcsBlueGreenDeploymentConfig.builder()
// The deployment will wait for approval for up to 8 hours before stopping the deployment
.deploymentApprovalWaitTime(Duration.hours(8))
.blueTargetGroup(blueTargetGroup)
.greenTargetGroup(greenTargetGroup)
.listener(listener)
.testListener(testListener)
.build())
.deploymentConfig(EcsDeploymentConfig.CANARY_10PERCENT_5MINUTES)
.build();
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationModeNested classes/interfaces inherited from interface software.amazon.awscdk.services.codedeploy.IBaseDeploymentConfig
IBaseDeploymentConfig.Jsii$DefaultNested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.services.codedeploy.IEcsDeploymentConfig
IEcsDeploymentConfig.Jsii$Default, IEcsDeploymentConfig.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.IResource
IResource.Jsii$Default -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final IEcsDeploymentConfigCodeDeploy predefined deployment configuration that shifts all traffic to the updated ECS task set at once.static final IEcsDeploymentConfigCodeDeploy predefined deployment configuration that shifts 10 percent of traffic in the first increment.static final IEcsDeploymentConfigCodeDeploy predefined deployment configuration that shifts 10 percent of traffic in the first increment.static final IEcsDeploymentConfigCodeDeploy predefined deployment configuration that shifts 10 percent of traffic every minute until all traffic is shifted.static final IEcsDeploymentConfigCodeDeploy predefined deployment configuration that shifts 10 percent of traffic every three minutes until all traffic is shifted.static final StringUniquely identifies this class. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedEcsDeploymentConfig(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedEcsDeploymentConfig(software.amazon.jsii.JsiiObjectRef objRef) EcsDeploymentConfig(software.constructs.Construct scope, String id) EcsDeploymentConfig(software.constructs.Construct scope, String id, EcsDeploymentConfigProps props) -
Method Summary
Modifier and TypeMethodDescriptionstatic IEcsDeploymentConfigfromEcsDeploymentConfigName(software.constructs.Construct scope, String id, String ecsDeploymentConfigName) Import a custom Deployment Configuration for an ECS Deployment Group defined outside the CDK.Methods inherited from class software.amazon.awscdk.services.codedeploy.BaseDeploymentConfig
fromDeploymentConfigName, getDeploymentConfigArn, getDeploymentConfigNameMethods inherited from class software.amazon.awscdk.Resource
applyRemovalPolicy, generatePhysicalName, getEnv, getPhysicalName, getResourceArnAttribute, getResourceNameAttribute, getStack, isOwnedResource, isResourceMethods inherited from class software.constructs.Construct
getNode, isConstruct, toStringMethods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface software.amazon.awscdk.services.codedeploy.IBaseDeploymentConfig
getDeploymentConfigArn, getDeploymentConfigNameMethods inherited from interface software.constructs.IConstruct
getNodeMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
ALL_AT_ONCE
CodeDeploy predefined deployment configuration that shifts all traffic to the updated ECS task set at once. -
CANARY_10_PERCENT_15_MINUTES
CodeDeploy predefined deployment configuration that shifts 10 percent of traffic in the first increment.The remaining 90 percent is deployed 15 minutes later.
-
CANARY_10_PERCENT_5_MINUTES
CodeDeploy predefined deployment configuration that shifts 10 percent of traffic in the first increment.The remaining 90 percent is deployed five minutes later.
-
LINEAR_10_PERCENT_EVERY_1_MINUTES
CodeDeploy predefined deployment configuration that shifts 10 percent of traffic every minute until all traffic is shifted. -
LINEAR_10_PERCENT_EVERY_3_MINUTES
CodeDeploy predefined deployment configuration that shifts 10 percent of traffic every three minutes until all traffic is shifted. -
PROPERTY_INJECTION_ID
Uniquely identifies this class.
-
-
Constructor Details
-
EcsDeploymentConfig
protected EcsDeploymentConfig(software.amazon.jsii.JsiiObjectRef objRef) -
EcsDeploymentConfig
protected EcsDeploymentConfig(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
EcsDeploymentConfig
@Stability(Stable) public EcsDeploymentConfig(@NotNull software.constructs.Construct scope, @NotNull String id, @Nullable EcsDeploymentConfigProps props) - Parameters:
scope- This parameter is required.id- This parameter is required.props-
-
EcsDeploymentConfig
@Stability(Stable) public EcsDeploymentConfig(@NotNull software.constructs.Construct scope, @NotNull String id) - Parameters:
scope- This parameter is required.id- This parameter is required.
-
-
Method Details
-
fromEcsDeploymentConfigName
@Stability(Stable) @NotNull public static IEcsDeploymentConfig fromEcsDeploymentConfigName(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String ecsDeploymentConfigName) Import a custom Deployment Configuration for an ECS Deployment Group defined outside the CDK.- Parameters:
scope- the parent Construct for this new Construct. This parameter is required.id- the logical ID of this new Construct. This parameter is required.ecsDeploymentConfigName- the name of the referenced custom Deployment Configuration. This parameter is required.- Returns:
- a Construct representing a reference to an existing custom Deployment Configuration
-