Class BackupPlanRuleProps
Properties for a BackupPlanRule.
Inheritance
Implements
Namespace: Amazon.CDK.AWS.Backup
Assembly: Amazon.CDK.AWS.Backup.dll
Syntax (csharp)
public class BackupPlanRuleProps : Object, IBackupPlanRuleProps
Syntax (vb)
Public Class BackupPlanRuleProps
Inherits Object
Implements IBackupPlanRuleProps
Remarks
ExampleMetadata: infused
Examples
BackupPlan plan;
plan.AddRule(new BackupPlanRule(new BackupPlanRuleProps {
CompletionWindow = Duration.Hours(2),
StartWindow = Duration.Hours(1),
ScheduleExpression = Schedule.Cron(new CronOptions { // Only cron expressions are supported
Day = "15",
Hour = "3",
Minute = "30" }),
MoveToColdStorageAfter = Duration.Days(30)
}));
Synopsis
Constructors
BackupPlanRuleProps() |
Properties
BackupVault | The backup vault where backups are. |
CompletionWindow | The duration after a backup job is successfully started before it must be completed or it is canceled by AWS Backup. |
DeleteAfter | Specifies the duration after creation that a recovery point is deleted. |
EnableContinuousBackup | Enables continuous backup and point-in-time restores (PITR). |
MoveToColdStorageAfter | Specifies the duration after creation that a recovery point is moved to cold storage. |
RuleName | A display name for the backup rule. |
ScheduleExpression | A CRON expression specifying when AWS Backup initiates a backup job. |
StartWindow | The duration after a backup is scheduled before a job is canceled if it doesn't start successfully. |
Constructors
BackupPlanRuleProps()
public BackupPlanRuleProps()
Properties
BackupVault
The backup vault where backups are.
public IBackupVault BackupVault { get; set; }
Property Value
Remarks
Default: - use the vault defined at the plan level. If not defined a new common vault for the plan will be created
CompletionWindow
The duration after a backup job is successfully started before it must be completed or it is canceled by AWS Backup.
public Duration CompletionWindow { get; set; }
Property Value
Remarks
Default: - 8 hours
DeleteAfter
Specifies the duration after creation that a recovery point is deleted.
public Duration DeleteAfter { get; set; }
Property Value
Remarks
Must be greater than moveToColdStorageAfter
.
Default: - recovery point is never deleted
EnableContinuousBackup
Enables continuous backup and point-in-time restores (PITR).
public Nullable<bool> EnableContinuousBackup { get; set; }
Property Value
System.Nullable<System.Boolean>
Remarks
Property deleteAfter
defines the retention period for the backup. It is mandatory if PITR is enabled.
If no value is specified, the retention period is set to 35 days which is the maximum retention period supported by PITR.
Property moveToColdStorageAfter
must not be specified because PITR does not support this option.
Default: false
MoveToColdStorageAfter
Specifies the duration after creation that a recovery point is moved to cold storage.
public Duration MoveToColdStorageAfter { get; set; }
Property Value
Remarks
Default: - recovery point is never moved to cold storage
RuleName
A display name for the backup rule.
public string RuleName { get; set; }
Property Value
System.String
Remarks
Default: - a CDK generated name
ScheduleExpression
A CRON expression specifying when AWS Backup initiates a backup job.
public Schedule ScheduleExpression { get; set; }
Property Value
Remarks
Default: - no schedule
StartWindow
The duration after a backup is scheduled before a job is canceled if it doesn't start successfully.
public Duration StartWindow { get; set; }
Property Value
Remarks
Default: - 8 hours