Class BackupPlan

java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.Resource
software.amazon.awscdk.services.backup.BackupPlan
All Implemented Interfaces:
IResource, IBackupPlan, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct, software.constructs.IDependable

@Generated(value="jsii-pacmak/1.101.0 (build b95fe5d)", date="2024-07-12T19:33:58.014Z") @Stability(Stable) public class BackupPlan extends Resource implements IBackupPlan
A backup plan.

Example:

 // Daily, weekly and monthly with 5 year retention
 BackupPlan plan = BackupPlan.dailyWeeklyMonthly5YearRetention(this, "Plan");
 
  • Constructor Details

    • BackupPlan

      protected BackupPlan(software.amazon.jsii.JsiiObjectRef objRef)
    • BackupPlan

      protected BackupPlan(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • BackupPlan

      @Stability(Stable) public BackupPlan(@NotNull software.constructs.Construct scope, @NotNull String id, @Nullable BackupPlanProps props)
      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      props -
    • BackupPlan

      @Stability(Stable) public BackupPlan(@NotNull software.constructs.Construct scope, @NotNull String id)
      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
  • Method Details

    • daily35DayRetention

      @Stability(Stable) @NotNull public static BackupPlan daily35DayRetention(@NotNull software.constructs.Construct scope, @NotNull String id, @Nullable IBackupVault backupVault)
      Daily with 35 day retention.

      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      backupVault -
    • daily35DayRetention

      @Stability(Stable) @NotNull public static BackupPlan daily35DayRetention(@NotNull software.constructs.Construct scope, @NotNull String id)
      Daily with 35 day retention.

      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
    • dailyMonthly1YearRetention

      @Stability(Stable) @NotNull public static BackupPlan dailyMonthly1YearRetention(@NotNull software.constructs.Construct scope, @NotNull String id, @Nullable IBackupVault backupVault)
      Daily and monthly with 1 year retention.

      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      backupVault -
    • dailyMonthly1YearRetention

      @Stability(Stable) @NotNull public static BackupPlan dailyMonthly1YearRetention(@NotNull software.constructs.Construct scope, @NotNull String id)
      Daily and monthly with 1 year retention.

      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
    • dailyWeeklyMonthly5YearRetention

      @Stability(Stable) @NotNull public static BackupPlan dailyWeeklyMonthly5YearRetention(@NotNull software.constructs.Construct scope, @NotNull String id, @Nullable IBackupVault backupVault)
      Daily, weekly and monthly with 5 year retention.

      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      backupVault -
    • dailyWeeklyMonthly5YearRetention

      @Stability(Stable) @NotNull public static BackupPlan dailyWeeklyMonthly5YearRetention(@NotNull software.constructs.Construct scope, @NotNull String id)
      Daily, weekly and monthly with 5 year retention.

      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
    • dailyWeeklyMonthly7YearRetention

      @Stability(Stable) @NotNull public static BackupPlan dailyWeeklyMonthly7YearRetention(@NotNull software.constructs.Construct scope, @NotNull String id, @Nullable IBackupVault backupVault)
      Daily, weekly and monthly with 7 year retention.

      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      backupVault -
    • dailyWeeklyMonthly7YearRetention

      @Stability(Stable) @NotNull public static BackupPlan dailyWeeklyMonthly7YearRetention(@NotNull software.constructs.Construct scope, @NotNull String id)
      Daily, weekly and monthly with 7 year retention.

      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
    • fromBackupPlanId

      @Stability(Stable) @NotNull public static IBackupPlan fromBackupPlanId(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String backupPlanId)
      Import an existing backup plan.

      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      backupPlanId - This parameter is required.
    • addRule

      @Stability(Stable) public void addRule(@NotNull BackupPlanRule rule)
      Adds a rule to a plan.

      Parameters:
      rule - the rule to add. This parameter is required.
    • addSelection

      @Stability(Stable) @NotNull public BackupSelection addSelection(@NotNull String id, @NotNull BackupSelectionOptions options)
      Adds a selection to this plan.

      Parameters:
      id - This parameter is required.
      options - This parameter is required.
    • getBackupPlanArn

      @Stability(Stable) @NotNull public String getBackupPlanArn()
      The ARN of the backup plan.
    • getBackupPlanId

      @Stability(Stable) @NotNull public String getBackupPlanId()
      The identifier of the backup plan.
      Specified by:
      getBackupPlanId in interface IBackupPlan
    • getBackupVault

      @Stability(Stable) @NotNull public IBackupVault getBackupVault()
      The backup vault where backups are stored if not defined at the rule level.
    • getVersionId

      @Stability(Stable) @NotNull public String getVersionId()
      Version Id.