@Generated(value="jsii-pacmak/1.67.0 (build 2c027f5)", date="2022-09-19T20:26:36.851Z") @Stability(value=Stable) public interface BackupSelectionOptions extends software.amazon.jsii.JsiiSerializable
Example:
BackupPlan plan;
Vpc vpc;
ITable myTable = Table.fromTableName(this, "Table", "myTableName");
DatabaseInstance myDatabaseInstance = DatabaseInstance.Builder.create(this, "DatabaseInstance")
.engine(DatabaseInstanceEngine.mysql(MySqlInstanceEngineProps.builder().version(MysqlEngineVersion.VER_8_0_26).build()))
.vpc(vpc)
.build();
DatabaseCluster myDatabaseCluster = DatabaseCluster.Builder.create(this, "DatabaseCluster")
.engine(DatabaseClusterEngine.auroraMysql(AuroraMysqlClusterEngineProps.builder().version(AuroraMysqlEngineVersion.VER_2_08_1).build()))
.credentials(Credentials.fromGeneratedSecret("clusteradmin"))
.instanceProps(InstanceProps.builder()
.vpc(vpc)
.build())
.build();
ServerlessCluster myServerlessCluster = ServerlessCluster.Builder.create(this, "ServerlessCluster")
.engine(DatabaseClusterEngine.AURORA_POSTGRESQL)
.parameterGroup(ParameterGroup.fromParameterGroupName(this, "ParameterGroup", "default.aurora-postgresql10"))
.vpc(vpc)
.build();
Construct myCoolConstruct = new Construct(this, "MyCoolConstruct");
plan.addSelection("Selection", BackupSelectionOptions.builder()
.resources(List.of(BackupResource.fromDynamoDbTable(myTable), BackupResource.fromRdsDatabaseInstance(myDatabaseInstance), BackupResource.fromRdsDatabaseCluster(myDatabaseCluster), BackupResource.fromRdsServerlessCluster(myServerlessCluster), BackupResource.fromTag("stage", "prod"), BackupResource.fromConstruct(myCoolConstruct)))
.build());
| Modifier and Type | Interface and Description |
|---|---|
static class |
BackupSelectionOptions.Builder
A builder for
BackupSelectionOptions |
static class |
BackupSelectionOptions.Jsii$Proxy
An implementation for
BackupSelectionOptions |
| Modifier and Type | Method and Description |
|---|---|
static BackupSelectionOptions.Builder |
builder() |
default Boolean |
getAllowRestores()
Whether to automatically give restores permissions to the role that AWS Backup uses.
|
default String |
getBackupSelectionName()
The name for this selection.
|
List<BackupResource> |
getResources()
The resources to backup.
|
default IRole |
getRole()
The role that AWS Backup uses to authenticate when backuping or restoring the resources.
|
@Stability(value=Stable) @NotNull List<BackupResource> getResources()
Use the helper static methods defined on BackupResource.
@Stability(value=Stable) @Nullable default Boolean getAllowRestores()
If true, the AWSBackupServiceRolePolicyForRestores managed
policy will be attached to the role.
Default: false
@Stability(value=Stable) @Nullable default String getBackupSelectionName()
Default: - a CDK generated name
@Stability(value=Stable) @Nullable default IRole getRole()
The AWSBackupServiceRolePolicyForBackup managed policy
will be attached to this role.
Default: - a new role will be created
@Stability(value=Stable) static BackupSelectionOptions.Builder builder()
BackupSelectionOptions.Builder of BackupSelectionOptionsCopyright © 2022. All rights reserved.