Class LambdaDeploymentGroup.Builder
java.lang.Object
software.amazon.awscdk.services.codedeploy.LambdaDeploymentGroup.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<LambdaDeploymentGroup>
- Enclosing class:
LambdaDeploymentGroup
@Stability(Stable)
public static final class LambdaDeploymentGroup.Builder
extends Object
implements software.amazon.jsii.Builder<LambdaDeploymentGroup>
A fluent builder for
LambdaDeploymentGroup
.-
Method Summary
Modifier and TypeMethodDescriptionThe CloudWatch alarms associated with this Deployment Group.Lambda Alias to shift traffic.application
(ILambdaApplication application) The reference to the CodeDeploy Lambda Application that this Deployment Group belongs to.autoRollback
(AutoRollbackConfig autoRollback) The auto-rollback configuration for this Deployment Group.build()
deploymentConfig
(ILambdaDeploymentConfig deploymentConfig) The Deployment Configuration this Deployment Group uses.deploymentGroupName
(String deploymentGroupName) The physical, human-readable name of the CodeDeploy Deployment Group.ignoreAlarmConfiguration
(Boolean ignoreAlarmConfiguration) Whether to skip the step of checking CloudWatch alarms during the deployment process.ignorePollAlarmsFailure
(Boolean ignorePollAlarmsFailure) Whether to continue a deployment even if fetching the alarm status from CloudWatch failed.The Lambda function to run after traffic routing starts.The Lambda function to run before traffic routing starts.The service Role of this Deployment Group.
-
Method Details
-
create
@Stability(Stable) public static LambdaDeploymentGroup.Builder create(software.constructs.Construct scope, String id) - Parameters:
scope
- This parameter is required.id
- This parameter is required.- Returns:
- a new instance of
LambdaDeploymentGroup.Builder
.
-
alias
Lambda Alias to shift traffic. Updating the version of the alias will trigger a CodeDeploy deployment.[disable-awslint:ref-via-interface] since we need to modify the alias CFN resource update policy
- Parameters:
alias
- Lambda Alias to shift traffic. Updating the version of the alias will trigger a CodeDeploy deployment. This parameter is required.- Returns:
this
-
alarms
The CloudWatch alarms associated with this Deployment Group.CodeDeploy will stop (and optionally roll back) a deployment if during it any of the alarms trigger.
Alarms can also be added after the Deployment Group is created using the
#addAlarm
method.Default: []
- Parameters:
alarms
- The CloudWatch alarms associated with this Deployment Group. This parameter is required.- Returns:
this
- See Also:
-
application
The reference to the CodeDeploy Lambda Application that this Deployment Group belongs to.Default: - One will be created for you.
- Parameters:
application
- The reference to the CodeDeploy Lambda Application that this Deployment Group belongs to. This parameter is required.- Returns:
this
-
autoRollback
@Stability(Stable) public LambdaDeploymentGroup.Builder autoRollback(AutoRollbackConfig autoRollback) The auto-rollback configuration for this Deployment Group.Default: - default AutoRollbackConfig.
- Parameters:
autoRollback
- The auto-rollback configuration for this Deployment Group. This parameter is required.- Returns:
this
-
deploymentConfig
@Stability(Stable) public LambdaDeploymentGroup.Builder deploymentConfig(ILambdaDeploymentConfig deploymentConfig) The Deployment Configuration this Deployment Group uses.Default: LambdaDeploymentConfig.CANARY_10PERCENT_5MINUTES
- Parameters:
deploymentConfig
- The Deployment Configuration this Deployment Group uses. This parameter is required.- Returns:
this
-
deploymentGroupName
@Stability(Stable) public LambdaDeploymentGroup.Builder deploymentGroupName(String deploymentGroupName) The physical, human-readable name of the CodeDeploy Deployment Group.Default: - An auto-generated name will be used.
- Parameters:
deploymentGroupName
- The physical, human-readable name of the CodeDeploy Deployment Group. This parameter is required.- Returns:
this
-
ignoreAlarmConfiguration
@Stability(Stable) public LambdaDeploymentGroup.Builder ignoreAlarmConfiguration(Boolean ignoreAlarmConfiguration) Whether to skip the step of checking CloudWatch alarms during the deployment process.Default: - false
- Parameters:
ignoreAlarmConfiguration
- Whether to skip the step of checking CloudWatch alarms during the deployment process. This parameter is required.- Returns:
this
-
ignorePollAlarmsFailure
@Stability(Stable) public LambdaDeploymentGroup.Builder ignorePollAlarmsFailure(Boolean ignorePollAlarmsFailure) Whether to continue a deployment even if fetching the alarm status from CloudWatch failed.Default: false
- Parameters:
ignorePollAlarmsFailure
- Whether to continue a deployment even if fetching the alarm status from CloudWatch failed. This parameter is required.- Returns:
this
-
postHook
The Lambda function to run after traffic routing starts.Default: - None.
- Parameters:
postHook
- The Lambda function to run after traffic routing starts. This parameter is required.- Returns:
this
-
preHook
The Lambda function to run before traffic routing starts.Default: - None.
- Parameters:
preHook
- The Lambda function to run before traffic routing starts. This parameter is required.- Returns:
this
-
role
The service Role of this Deployment Group.Default: - A new Role will be created.
- Parameters:
role
- The service Role of this Deployment Group. This parameter is required.- Returns:
this
-
build
- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<LambdaDeploymentGroup>
- Returns:
- a newly built instance of
LambdaDeploymentGroup
.
-