Class CfnDeploymentConfig
- All Implemented Interfaces:
IConstruct
,IDependable
,IInspectable
,software.amazon.jsii.JsiiSerializable
,software.constructs.IConstruct
AWS::CodeDeploy::DeploymentConfig
.
The AWS::CodeDeploy::DeploymentConfig
resource creates a set of deployment rules, deployment success conditions, and deployment failure conditions that AWS CodeDeploy uses during a deployment. The deployment configuration specifies, through the use of a MinimumHealthyHosts
value, the number or percentage of instances that must remain available at any time during a deployment.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import software.amazon.awscdk.services.codedeploy.*; CfnDeploymentConfig cfnDeploymentConfig = CfnDeploymentConfig.Builder.create(this, "MyCfnDeploymentConfig") .computePlatform("computePlatform") .deploymentConfigName("deploymentConfigName") .minimumHealthyHosts(MinimumHealthyHostsProperty.builder() .type("type") .value(123) .build()) .trafficRoutingConfig(TrafficRoutingConfigProperty.builder() .type("type") // the properties below are optional .timeBasedCanary(TimeBasedCanaryProperty.builder() .canaryInterval(123) .canaryPercentage(123) .build()) .timeBasedLinear(TimeBasedLinearProperty.builder() .linearInterval(123) .linearPercentage(123) .build()) .build()) .build();
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic final class
A fluent builder forCfnDeploymentConfig
.static interface
MinimumHealthyHosts
is a property of the DeploymentConfig resource that defines how many instances must remain healthy during an AWS CodeDeploy deployment.static interface
A configuration that shifts traffic from one version of a Lambda function or Amazon ECS task set to another in two increments.static interface
A configuration that shifts traffic from one version of a Lambda function or ECS task set to another in equal increments, with an equal number of minutes between each increment.static interface
The configuration that specifies how traffic is shifted from one version of a Lambda function to another version during an AWS Lambda deployment, or from one Amazon ECS task set to another during an Amazon ECS deployment.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationMode
Nested classes/interfaces inherited from interface software.amazon.awscdk.core.IConstruct
IConstruct.Jsii$Default
Nested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$Default
Nested classes/interfaces inherited from interface software.amazon.awscdk.core.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$Proxy
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
The CloudFormation resource type name for this resource class. -
Constructor Summary
ModifierConstructorDescriptionCfnDeploymentConfig
(Construct scope, String id) Create a newAWS::CodeDeploy::DeploymentConfig
.CfnDeploymentConfig
(Construct scope, String id, CfnDeploymentConfigProps props) Create a newAWS::CodeDeploy::DeploymentConfig
.protected
CfnDeploymentConfig
(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protected
CfnDeploymentConfig
(software.amazon.jsii.JsiiObjectRef objRef) -
Method Summary
Modifier and TypeMethodDescriptionThe destination platform type for the deployment (Lambda
,Server
, orECS
).A name for the deployment configuration.The minimum number of healthy instances that should be available at any time during the deployment.The configuration that specifies how the deployment traffic is routed.void
inspect
(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties
(Map<String, Object> props) void
setComputePlatform
(String value) The destination platform type for the deployment (Lambda
,Server
, orECS
).void
setDeploymentConfigName
(String value) A name for the deployment configuration.void
The minimum number of healthy instances that should be available at any time during the deployment.void
The minimum number of healthy instances that should be available at any time during the deployment.void
The configuration that specifies how the deployment traffic is routed.void
The configuration that specifies how the deployment traffic is routed.Methods inherited from class software.amazon.awscdk.core.CfnResource
addDeletionOverride, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, isCfnResource, shouldSynthesize, toString, validateProperties
Methods inherited from class software.amazon.awscdk.core.CfnRefElement
getRef
Methods inherited from class software.amazon.awscdk.core.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalId
Methods inherited from class software.amazon.awscdk.core.Construct
getNode, isConstruct, onPrepare, onSynthesize, onValidate, prepare, synthesize, validate
Methods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
-
-
Constructor Details
-
CfnDeploymentConfig
protected CfnDeploymentConfig(software.amazon.jsii.JsiiObjectRef objRef) -
CfnDeploymentConfig
protected CfnDeploymentConfig(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnDeploymentConfig
@Stability(Stable) public CfnDeploymentConfig(@NotNull Construct scope, @NotNull String id, @Nullable CfnDeploymentConfigProps props) Create a newAWS::CodeDeploy::DeploymentConfig
.- Parameters:
scope
-- scope in which this resource is defined.
id
-- scoped id of the resource.
props
-- resource properties.
-
CfnDeploymentConfig
Create a newAWS::CodeDeploy::DeploymentConfig
.- Parameters:
scope
-- scope in which this resource is defined.
id
-- scoped id of the resource.
-
-
Method Details
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspect
in interfaceIInspectable
- Parameters:
inspector
-- tree inspector to collect and process attributes.
-
renderProperties
@Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String, Object> props) - Overrides:
renderProperties
in classCfnResource
- Parameters:
props
- This parameter is required.
-
getCfnProperties
- Overrides:
getCfnProperties
in classCfnResource
-
getComputePlatform
The destination platform type for the deployment (Lambda
,Server
, orECS
). -
setComputePlatform
The destination platform type for the deployment (Lambda
,Server
, orECS
). -
getDeploymentConfigName
A name for the deployment configuration.If you don't specify a name, AWS CloudFormation generates a unique physical ID and uses that ID for the deployment configuration name. For more information, see Name Type .
If you specify a name, you cannot perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you must replace the resource, specify a new name.
-
setDeploymentConfigName
A name for the deployment configuration.If you don't specify a name, AWS CloudFormation generates a unique physical ID and uses that ID for the deployment configuration name. For more information, see Name Type .
If you specify a name, you cannot perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you must replace the resource, specify a new name.
-
getMinimumHealthyHosts
The minimum number of healthy instances that should be available at any time during the deployment.There are two parameters expected in the input: type and value.
The type parameter takes either of the following values:
- HOST_COUNT: The value parameter represents the minimum number of healthy instances as an absolute value.
- FLEET_PERCENT: The value parameter represents the minimum number of healthy instances as a percentage of the total number of instances in the deployment. If you specify FLEET_PERCENT, at the start of the deployment, AWS CodeDeploy converts the percentage to the equivalent number of instance and rounds up fractional instances.
The value parameter takes an integer.
For example, to set a minimum of 95% healthy instance, specify a type of FLEET_PERCENT and a value of 95.
For more information about instance health, see CodeDeploy Instance Health in the AWS CodeDeploy User Guide.
-
setMinimumHealthyHosts
@Stability(Stable) public void setMinimumHealthyHosts(@Nullable CfnDeploymentConfig.MinimumHealthyHostsProperty value) The minimum number of healthy instances that should be available at any time during the deployment.There are two parameters expected in the input: type and value.
The type parameter takes either of the following values:
- HOST_COUNT: The value parameter represents the minimum number of healthy instances as an absolute value.
- FLEET_PERCENT: The value parameter represents the minimum number of healthy instances as a percentage of the total number of instances in the deployment. If you specify FLEET_PERCENT, at the start of the deployment, AWS CodeDeploy converts the percentage to the equivalent number of instance and rounds up fractional instances.
The value parameter takes an integer.
For example, to set a minimum of 95% healthy instance, specify a type of FLEET_PERCENT and a value of 95.
For more information about instance health, see CodeDeploy Instance Health in the AWS CodeDeploy User Guide.
-
setMinimumHealthyHosts
The minimum number of healthy instances that should be available at any time during the deployment.There are two parameters expected in the input: type and value.
The type parameter takes either of the following values:
- HOST_COUNT: The value parameter represents the minimum number of healthy instances as an absolute value.
- FLEET_PERCENT: The value parameter represents the minimum number of healthy instances as a percentage of the total number of instances in the deployment. If you specify FLEET_PERCENT, at the start of the deployment, AWS CodeDeploy converts the percentage to the equivalent number of instance and rounds up fractional instances.
The value parameter takes an integer.
For example, to set a minimum of 95% healthy instance, specify a type of FLEET_PERCENT and a value of 95.
For more information about instance health, see CodeDeploy Instance Health in the AWS CodeDeploy User Guide.
-
getTrafficRoutingConfig
The configuration that specifies how the deployment traffic is routed. -
setTrafficRoutingConfig
The configuration that specifies how the deployment traffic is routed. -
setTrafficRoutingConfig
@Stability(Stable) public void setTrafficRoutingConfig(@Nullable CfnDeploymentConfig.TrafficRoutingConfigProperty value) The configuration that specifies how the deployment traffic is routed.
-