@Generated(value="jsii-pacmak/1.67.0 (build 2c027f5)", date="2022-09-19T20:26:36.854Z") @Stability(value=Stable) public class CfnBackupPlan extends CfnResource implements IInspectable
Contains an optional backup plan display name and an array of BackupRule objects, each of which specifies a backup rule. Each rule in a backup plan is a separate scheduled task and can back up a different selection of AWS resources.
For a sample AWS CloudFormation template, see the AWS Backup Developer Guide .
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.backup.*;
Object backupOptions;
CfnBackupPlan cfnBackupPlan = CfnBackupPlan.Builder.create(this, "MyCfnBackupPlan")
.backupPlan(BackupPlanResourceTypeProperty.builder()
.backupPlanName("backupPlanName")
.backupPlanRule(List.of(BackupRuleResourceTypeProperty.builder()
.ruleName("ruleName")
.targetBackupVault("targetBackupVault")
// the properties below are optional
.completionWindowMinutes(123)
.copyActions(List.of(CopyActionResourceTypeProperty.builder()
.destinationBackupVaultArn("destinationBackupVaultArn")
// the properties below are optional
.lifecycle(LifecycleResourceTypeProperty.builder()
.deleteAfterDays(123)
.moveToColdStorageAfterDays(123)
.build())
.build()))
.enableContinuousBackup(false)
.lifecycle(LifecycleResourceTypeProperty.builder()
.deleteAfterDays(123)
.moveToColdStorageAfterDays(123)
.build())
.recoveryPointTags(Map.of(
"recoveryPointTagsKey", "recoveryPointTags"))
.scheduleExpression("scheduleExpression")
.startWindowMinutes(123)
.build()))
// the properties below are optional
.advancedBackupSettings(List.of(AdvancedBackupSettingResourceTypeProperty.builder()
.backupOptions(backupOptions)
.resourceType("resourceType")
.build()))
.build())
// the properties below are optional
.backupPlanTags(Map.of(
"backupPlanTagsKey", "backupPlanTags"))
.build();
| Modifier and Type | Class and Description |
|---|---|
static interface |
CfnBackupPlan.AdvancedBackupSettingResourceTypeProperty
Specifies an object containing resource type and backup options.
|
static interface |
CfnBackupPlan.BackupPlanResourceTypeProperty
Specifies an object containing properties used to create a backup plan.
|
static interface |
CfnBackupPlan.BackupRuleResourceTypeProperty
Specifies an object containing properties used to schedule a task to back up a selection of resources.
|
static class |
CfnBackupPlan.Builder
A fluent builder for
CfnBackupPlan. |
static interface |
CfnBackupPlan.CopyActionResourceTypeProperty
Copies backups created by a backup rule to another vault.
|
static interface |
CfnBackupPlan.LifecycleResourceTypeProperty
Specifies an object containing an array of `Transition` objects that determine how long in days before a recovery point transitions to cold storage or is deleted.
|
software.amazon.jsii.JsiiObject.InitializationModeIInspectable.Jsii$Default, IInspectable.Jsii$Proxy| Modifier and Type | Field and Description |
|---|---|
static String |
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
|
| Modifier | Constructor and Description |
|---|---|
|
CfnBackupPlan(software.constructs.Construct scope,
String id,
CfnBackupPlanProps props)
Create a new `AWS::Backup::BackupPlan`.
|
protected |
CfnBackupPlan(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
CfnBackupPlan(software.amazon.jsii.JsiiObjectRef objRef) |
| Modifier and Type | Method and Description |
|---|---|
String |
getAttrBackupPlanArn()
An Amazon Resource Name (ARN) that uniquely identifies a backup plan;
|
String |
getAttrBackupPlanId()
Uniquely identifies a backup plan.
|
String |
getAttrVersionId()
Unique, randomly generated, Unicode, UTF-8 encoded strings that are at most 1,024 bytes long.
|
Object |
getBackupPlan()
Uniquely identifies the backup plan to be associated with the selection of resources.
|
Object |
getBackupPlanTags()
To help organize your resources, you can assign your own metadata to the resources that you create.
|
protected Map<String,Object> |
getCfnProperties() |
void |
inspect(TreeInspector inspector)
Examines the CloudFormation resource and discloses attributes.
|
protected Map<String,Object> |
renderProperties(Map<String,Object> props) |
void |
setBackupPlan(CfnBackupPlan.BackupPlanResourceTypeProperty value)
Uniquely identifies the backup plan to be associated with the selection of resources.
|
void |
setBackupPlan(IResolvable value)
Uniquely identifies the backup plan to be associated with the selection of resources.
|
void |
setBackupPlanTags(IResolvable value)
To help organize your resources, you can assign your own metadata to the resources that you create.
|
void |
setBackupPlanTags(Map<String,String> value)
To help organize your resources, you can assign your own metadata to the resources that you create.
|
addDeletionOverride, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, shouldSynthesize, toString, validatePropertiesgetRefgetCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalIdjsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet@Stability(value=Stable) public static final String CFN_RESOURCE_TYPE_NAME
protected CfnBackupPlan(software.amazon.jsii.JsiiObjectRef objRef)
protected CfnBackupPlan(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
@Stability(value=Stable)
public CfnBackupPlan(@NotNull
software.constructs.Construct scope,
@NotNull
String id,
@NotNull
CfnBackupPlanProps props)
scope - - scope in which this resource is defined. This parameter is required.id - - scoped id of the resource. This parameter is required.props - - resource properties. This parameter is required.@Stability(value=Stable)
public void inspect(@NotNull
TreeInspector inspector)
inspect in interface IInspectableinspector - - tree inspector to collect and process attributes. This parameter is required.@Stability(value=Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String,Object> props)
renderProperties in class CfnResourceprops - This parameter is required.@Stability(value=Stable) @NotNull public String getAttrBackupPlanArn()
for example, arn:aws:backup:us-east-1:123456789012:plan:8F81F553-3A74-4A3F-B93D-B3360DC80C50 .
@Stability(value=Stable) @NotNull public String getAttrBackupPlanId()
@Stability(value=Stable) @NotNull public String getAttrVersionId()
Version Ids cannot be edited.
@Stability(value=Stable) @NotNull protected Map<String,Object> getCfnProperties()
getCfnProperties in class CfnResource@Stability(value=Stable) @NotNull public Object getBackupPlan()
@Stability(value=Stable)
public void setBackupPlan(@NotNull
CfnBackupPlan.BackupPlanResourceTypeProperty value)
@Stability(value=Stable)
public void setBackupPlan(@NotNull
IResolvable value)
@Stability(value=Stable) @Nullable public Object getBackupPlanTags()
Each tag is a key-value pair. The specified tags are assigned to all backups created with this plan.
@Stability(value=Stable)
public void setBackupPlanTags(@Nullable
IResolvable value)
Each tag is a key-value pair. The specified tags are assigned to all backups created with this plan.
@Stability(value=Stable)
public void setBackupPlanTags(@Nullable
Map<String,String> value)
Each tag is a key-value pair. The specified tags are assigned to all backups created with this plan.
Copyright © 2022. All rights reserved.