Class CfnPlan
java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.CfnElement
software.amazon.awscdk.CfnRefElement
software.amazon.awscdk.CfnResource
software.amazon.awscdk.services.arcregionswitch.CfnPlan
- All Implemented Interfaces:
IInspectable,IPlanRef,IEnvironmentAware,ITaggableV2,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
@Generated(value="jsii-pacmak/1.119.0 (build 1634eac)",
date="2025-11-17T14:40:45.601Z")
@Stability(Stable)
public class CfnPlan
extends CfnResource
implements IInspectable, IPlanRef, ITaggableV2
Represents a Region switch plan.
A plan defines the steps required to shift traffic from one AWS Region to another.
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.arcregionswitch.*;
StepProperty stepProperty_;
CfnPlan cfnPlan = CfnPlan.Builder.create(this, "MyCfnPlan")
.executionRole("executionRole")
.name("name")
.recoveryApproach("recoveryApproach")
.regions(List.of("regions"))
.workflows(List.of(WorkflowProperty.builder()
.workflowTargetAction("workflowTargetAction")
// the properties below are optional
.steps(List.of(StepProperty.builder()
.executionBlockConfiguration(ExecutionBlockConfigurationProperty.builder()
.arcRoutingControlConfig(ArcRoutingControlConfigurationProperty.builder()
.regionAndRoutingControls(Map.of(
"regionAndRoutingControlsKey", List.of(ArcRoutingControlStateProperty.builder()
.routingControlArn("routingControlArn")
.state("state")
.build())))
// the properties below are optional
.crossAccountRole("crossAccountRole")
.externalId("externalId")
.timeoutMinutes(123)
.build())
.customActionLambdaConfig(CustomActionLambdaConfigurationProperty.builder()
.lambdas(List.of(LambdasProperty.builder()
.arn("arn")
.crossAccountRole("crossAccountRole")
.externalId("externalId")
.build()))
.regionToRun("regionToRun")
.retryIntervalMinutes(123)
// the properties below are optional
.timeoutMinutes(123)
.ungraceful(LambdaUngracefulProperty.builder()
.behavior("behavior")
.build())
.build())
.ec2AsgCapacityIncreaseConfig(Ec2AsgCapacityIncreaseConfigurationProperty.builder()
.asgs(List.of(AsgProperty.builder()
.arn("arn")
.crossAccountRole("crossAccountRole")
.externalId("externalId")
.build()))
// the properties below are optional
.capacityMonitoringApproach("capacityMonitoringApproach")
.targetPercent(123)
.timeoutMinutes(123)
.ungraceful(Ec2UngracefulProperty.builder()
.minimumSuccessPercentage(123)
.build())
.build())
.ecsCapacityIncreaseConfig(EcsCapacityIncreaseConfigurationProperty.builder()
.services(List.of(ServiceProperty.builder()
.clusterArn("clusterArn")
.crossAccountRole("crossAccountRole")
.externalId("externalId")
.serviceArn("serviceArn")
.build()))
// the properties below are optional
.capacityMonitoringApproach("capacityMonitoringApproach")
.targetPercent(123)
.timeoutMinutes(123)
.ungraceful(EcsUngracefulProperty.builder()
.minimumSuccessPercentage(123)
.build())
.build())
.eksResourceScalingConfig(EksResourceScalingConfigurationProperty.builder()
.kubernetesResourceType(KubernetesResourceTypeProperty.builder()
.apiVersion("apiVersion")
.kind("kind")
.build())
// the properties below are optional
.capacityMonitoringApproach("capacityMonitoringApproach")
.eksClusters(List.of(EksClusterProperty.builder()
.clusterArn("clusterArn")
// the properties below are optional
.crossAccountRole("crossAccountRole")
.externalId("externalId")
.build()))
.scalingResources(List.of(Map.of(
"scalingResourcesKey", Map.of(
"scalingResourcesKey", KubernetesScalingResourceProperty.builder()
.name("name")
.namespace("namespace")
// the properties below are optional
.hpaName("hpaName")
.build()))))
.targetPercent(123)
.timeoutMinutes(123)
.ungraceful(EksResourceScalingUngracefulProperty.builder()
.minimumSuccessPercentage(123)
.build())
.build())
.executionApprovalConfig(ExecutionApprovalConfigurationProperty.builder()
.approvalRole("approvalRole")
// the properties below are optional
.timeoutMinutes(123)
.build())
.globalAuroraConfig(GlobalAuroraConfigurationProperty.builder()
.behavior("behavior")
.databaseClusterArns(List.of("databaseClusterArns"))
.globalClusterIdentifier("globalClusterIdentifier")
// the properties below are optional
.crossAccountRole("crossAccountRole")
.externalId("externalId")
.timeoutMinutes(123)
.ungraceful(GlobalAuroraUngracefulProperty.builder()
.ungraceful("ungraceful")
.build())
.build())
.parallelConfig(ParallelExecutionBlockConfigurationProperty.builder()
.steps(List.of(stepProperty_))
.build())
.regionSwitchPlanConfig(RegionSwitchPlanConfigurationProperty.builder()
.arn("arn")
// the properties below are optional
.crossAccountRole("crossAccountRole")
.externalId("externalId")
.build())
.route53HealthCheckConfig(Route53HealthCheckConfigurationProperty.builder()
.hostedZoneId("hostedZoneId")
.recordName("recordName")
// the properties below are optional
.crossAccountRole("crossAccountRole")
.externalId("externalId")
.recordSets(List.of(Route53ResourceRecordSetProperty.builder()
.recordSetIdentifier("recordSetIdentifier")
.region("region")
.build()))
.timeoutMinutes(123)
.build())
.build())
.executionBlockType("executionBlockType")
.name("name")
// the properties below are optional
.description("description")
.build()))
.workflowDescription("workflowDescription")
.workflowTargetRegion("workflowTargetRegion")
.build()))
// the properties below are optional
.associatedAlarms(Map.of(
"associatedAlarmsKey", AssociatedAlarmProperty.builder()
.alarmType("alarmType")
.resourceIdentifier("resourceIdentifier")
// the properties below are optional
.crossAccountRole("crossAccountRole")
.externalId("externalId")
.build()))
.description("description")
.primaryRegion("primaryRegion")
.recoveryTimeObjectiveMinutes(123)
.tags(Map.of(
"tagsKey", "tags"))
.triggers(List.of(TriggerProperty.builder()
.action("action")
.conditions(List.of(TriggerConditionProperty.builder()
.associatedAlarmName("associatedAlarmName")
.condition("condition")
.build()))
.minDelayMinutesBetweenExecutions(123)
.targetRegion("targetRegion")
// the properties below are optional
.description("description")
.build()))
.build();
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfaceConfiguration for ARC routing controls used in a Region switch plan.static interfaceExample:static interfaceConfiguration for an Amazon EC2 Auto Scaling group used in a Region switch plan.static interfaceAn Amazon CloudWatch alarm associated with a Region switch plan.static final classA fluent builder forCfnPlan.static interfaceConfiguration for AWS Lambda functions that perform custom actions during a Region switch.static interfaceConfiguration for increasing the capacity of Amazon EC2 Auto Scaling groups during a Region switch.static interfaceConfiguration for handling failures when performing operations on EC2 resources.static interfaceThe configuration for an AWS ECS capacity increase.static interfaceThe settings for ungraceful execution.static interfaceThe AWS EKS cluster execution block configuration.static interfaceThe AWS EKS resource scaling configuration.static interfaceThe ungraceful settings for AWS EKS resource scaling.static interfaceConfiguration for approval steps in a Region switch plan execution.static interfaceExecution block configurations for a workflow in a Region switch plan.static interfaceConfiguration for Amazon Aurora global databases used in a Region switch plan.static interfaceConfiguration for handling failures when performing operations on Aurora global databases.static interfaceExample:static interfaceDefines the type of Kubernetes resource to scale in an Amazon EKS cluster.static interfaceDefines a Kubernetes resource to scale in an Amazon EKS cluster.static interfaceConfiguration for AWS Lambda functions used in a Region switch plan.static interfaceConfiguration for handling failures when invoking Lambda functions.static interfaceConfiguration for steps that should be executed in parallel during a Region switch.static interfaceConfiguration for nested Region switch plans.static interfaceThe Amazon Route 53 health check configuration.static interfaceExample:static interfaceThe Amazon Route 53 record set.static interfaceThe service for a cross account role.static interfaceRepresents a step in a Region switch plan workflow.static interfaceDefines a condition that must be met for a trigger to fire.static interfaceDefines a condition that can automatically trigger the execution of a Region switch plan.static interfaceRepresents a workflow in a Region switch plan.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationModeNested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.interfaces.arcregionswitch.IPlanRef
IPlanRef.Jsii$Default, IPlanRef.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.ITaggableV2
ITaggableV2.Jsii$Default, ITaggableV2.Jsii$Proxy -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe CloudFormation resource type name for this resource class. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCfnPlan(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedCfnPlan(software.amazon.jsii.JsiiObjectRef objRef) CfnPlan(software.constructs.Construct scope, String id, CfnPlanProps props) Create a newAWS::ARCRegionSwitch::Plan. -
Method Summary
Modifier and TypeMethodDescriptionThe associated application health alarms for a plan.The Amazon Resource Name (ARN) of the plan.The owner of a plan.The version for the plan.Tag Manager which manages the tags for this resource.The description for a plan.The execution role for a plan.getName()The name for a plan.A reference to a Plan resource.The primary Region for a plan.The recovery approach for a Region switch plan, which can be active/active (activeActive) or active/passive (activePassive).The recovery time objective for a plan.The AWS Regions for a plan.getTags()The triggers for a plan.The workflows for a plan.voidinspect(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties(Map<String, Object> props) voidsetAssociatedAlarms(Map<String, Object> value) The associated application health alarms for a plan.voidsetAssociatedAlarms(IResolvable value) The associated application health alarms for a plan.voidsetDescription(String value) The description for a plan.voidsetExecutionRole(String value) The execution role for a plan.voidThe name for a plan.voidsetPrimaryRegion(String value) The primary Region for a plan.voidsetRecoveryApproach(String value) The recovery approach for a Region switch plan, which can be active/active (activeActive) or active/passive (activePassive).voidThe recovery time objective for a plan.voidsetRegions(List<String> value) The AWS Regions for a plan.voidvoidsetTriggers(List<Object> value) The triggers for a plan.voidsetTriggers(IResolvable value) The triggers for a plan.voidsetWorkflows(List<Object> value) The workflows for a plan.voidsetWorkflows(IResolvable value) The workflows for a plan.Methods inherited from class software.amazon.awscdk.CfnResource
addDeletionOverride, addDependency, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getAtt, getCfnOptions, getCfnResourceType, getEnv, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, obtainDependencies, obtainResourceDependencies, removeDependency, replaceDependency, shouldSynthesize, toString, validatePropertiesMethods inherited from class software.amazon.awscdk.CfnRefElement
getRefMethods inherited from class software.amazon.awscdk.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalIdMethods inherited from class software.constructs.Construct
getNode, isConstructMethods 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.constructs.IConstruct
getNodeMethods inherited from interface software.amazon.awscdk.interfaces.IEnvironmentAware
getEnvMethods 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
-
CfnPlan
protected CfnPlan(software.amazon.jsii.JsiiObjectRef objRef) -
CfnPlan
protected CfnPlan(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnPlan
@Stability(Stable) public CfnPlan(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnPlanProps props) Create a newAWS::ARCRegionSwitch::Plan.- Parameters:
scope- Scope in which this resource is defined. This parameter is required.id- Construct identifier for this resource (unique in its scope). This parameter is required.props- Resource properties. This parameter is required.
-
-
Method Details
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspectin interfaceIInspectable- Parameters:
inspector- tree inspector to collect and process attributes. This parameter is required.
-
renderProperties
@Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String, Object> props) - Overrides:
renderPropertiesin classCfnResource- Parameters:
props- This parameter is required.
-
getAttrArn
The Amazon Resource Name (ARN) of the plan. -
getAttrHealthChecksForPlan
-
getAttrOwner
The owner of a plan. -
getAttrPlanHealthChecks
-
getAttrRoute53HealthChecks
-
getAttrVersion
The version for the plan. -
getCdkTagManager
Tag Manager which manages the tags for this resource.- Specified by:
getCdkTagManagerin interfaceITaggableV2
-
getCfnProperties
- Overrides:
getCfnPropertiesin classCfnResource
-
getPlanRef
A reference to a Plan resource.- Specified by:
getPlanRefin interfaceIPlanRef
-
getExecutionRole
The execution role for a plan. -
setExecutionRole
The execution role for a plan. -
getName
The name for a plan. -
setName
The name for a plan. -
getRecoveryApproach
The recovery approach for a Region switch plan, which can be active/active (activeActive) or active/passive (activePassive). -
setRecoveryApproach
The recovery approach for a Region switch plan, which can be active/active (activeActive) or active/passive (activePassive). -
getRegions
The AWS Regions for a plan. -
setRegions
The AWS Regions for a plan. -
getWorkflows
The workflows for a plan.Returns union: either
IResolvableor Listinvalid input: '<'eitherIResolvableorCfnPlan.WorkflowProperty> -
setWorkflows
The workflows for a plan. -
setWorkflows
The workflows for a plan. -
getAssociatedAlarms
The associated application health alarms for a plan.Returns union: either
IResolvableor Mapinvalid input: '<'String, eitherIResolvableorCfnPlan.AssociatedAlarmProperty> -
setAssociatedAlarms
The associated application health alarms for a plan. -
setAssociatedAlarms
The associated application health alarms for a plan. -
getDescription
The description for a plan. -
setDescription
The description for a plan. -
getPrimaryRegion
The primary Region for a plan. -
setPrimaryRegion
The primary Region for a plan. -
getRecoveryTimeObjectiveMinutes
The recovery time objective for a plan. -
setRecoveryTimeObjectiveMinutes
The recovery time objective for a plan. -
getTags
-
setTags
-
getTriggers
The triggers for a plan.Returns union: either
IResolvableor Listinvalid input: '<'eitherIResolvableorCfnPlan.TriggerProperty> -
setTriggers
The triggers for a plan. -
setTriggers
The triggers for a plan.
-