class BackupPlanRule
Language | Type name |
---|---|
.NET | Amazon.CDK.AWS.Backup.BackupPlanRule |
Go | github.com/aws/aws-cdk-go/awscdk/v2/awsbackup#BackupPlanRule |
Java | software.amazon.awscdk.services.backup.BackupPlanRule |
Python | aws_cdk.aws_backup.BackupPlanRule |
TypeScript (source) | aws-cdk-lib » aws_backup » BackupPlanRule |
A backup plan rule.
Example
declare const plan: backup.BackupPlan;
plan.addRule(new backup.BackupPlanRule({
enableContinuousBackup: true,
deleteAfter: Duration.days(14),
}));
Initializer
new BackupPlanRule(props: BackupPlanRuleProps)
Parameters
- props
Backup
— Rule properties.Plan Rule Props
Properties
Name | Type | Description |
---|---|---|
props | Backup | Properties of BackupPlanRule. |
props
Type:
Backup
Properties of BackupPlanRule.
Methods
Name | Description |
---|---|
static daily(backupVault?) | Daily with 35 days retention. |
static monthly1 | Monthly 1 year retention, move to cold storage after 1 month. |
static monthly5 | Monthly 5 year retention, move to cold storage after 3 months. |
static monthly7 | Monthly 7 year retention, move to cold storage after 3 months. |
static weekly(backupVault?) | Weekly with 3 months retention. |
static daily(backupVault?)
public static daily(backupVault?: IBackupVault): BackupPlanRule
Parameters
- backupVault
IBackup
Vault
Returns
Daily with 35 days retention.
Year(backupVault?)
static monthly1public static monthly1Year(backupVault?: IBackupVault): BackupPlanRule
Parameters
- backupVault
IBackup
Vault
Returns
Monthly 1 year retention, move to cold storage after 1 month.
Year(backupVault?)
static monthly5public static monthly5Year(backupVault?: IBackupVault): BackupPlanRule
Parameters
- backupVault
IBackup
Vault
Returns
Monthly 5 year retention, move to cold storage after 3 months.
Year(backupVault?)
static monthly7public static monthly7Year(backupVault?: IBackupVault): BackupPlanRule
Parameters
- backupVault
IBackup
Vault
Returns
Monthly 7 year retention, move to cold storage after 3 months.
static weekly(backupVault?)
public static weekly(backupVault?: IBackupVault): BackupPlanRule
Parameters
- backupVault
IBackup
Vault
Returns
Weekly with 3 months retention.