Interface AutoRollbackConfig

All Superinterfaces:
All Known Implementing Classes:

@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)", date="2023-06-19T16:30:46.277Z") @Stability(Stable) public interface AutoRollbackConfig extends
The configuration for automatically rolling back deployments in a given Deployment Group.


 ServerApplication application;
 AutoScalingGroup asg;
 Alarm alarm;
 ServerDeploymentGroup deploymentGroup = ServerDeploymentGroup.Builder.create(this, "CodeDeployDeploymentGroup")
         // adds User Data that installs the CodeDeploy agent on your auto-scaling groups hosts
         // default: true
         // adds EC2 instances matching tags
         .ec2InstanceTags(new InstanceTagSet(Map.of(
                 // any instance with tags satisfying
                 // key1=v1 or key1=v2 or key2 (any value) or value v3 (any key)
                 // will match this group
                 "key1", List.of("v1", "v2"),
                 "key2", List.of(),
                 "", List.of("v3"))))
         // adds on-premise instances matching tags
         .onPremiseInstanceTags(new InstanceTagSet(Map.of(
                 "key1", List.of("v1", "v2")), Map.of(
                 "key2", List.of("v3"))))
         // CloudWatch alarms
         // whether to ignore failure to fetch the status of alarms from CloudWatch
         // default: false
         // auto-rollback configuration
                 .failedDeployment(true) // default: true
                 .stoppedDeployment(true) // default: false
  • Method Details

    • getDeploymentInAlarm

      @Stability(Stable) @Nullable default Boolean getDeploymentInAlarm()
      Whether to automatically roll back a deployment during which one of the configured CloudWatch alarms for this Deployment Group went off.

      Default: true if you've provided any Alarms with the `alarms` property, false otherwise

    • getFailedDeployment

      @Stability(Stable) @Nullable default Boolean getFailedDeployment()
      Whether to automatically roll back a deployment that fails.

      Default: true

    • getStoppedDeployment

      @Stability(Stable) @Nullable default Boolean getStoppedDeployment()
      Whether to automatically roll back a deployment that was manually stopped.

      Default: false

    • builder

      @Stability(Stable) static AutoRollbackConfig.Builder builder()
      a AutoRollbackConfig.Builder of AutoRollbackConfig