Interface SnapshotCredentialsFromGeneratedPasswordOptions
- All Superinterfaces:
software.amazon.jsii.JsiiSerializable
- All Known Implementing Classes:
SnapshotCredentialsFromGeneratedPasswordOptions.Jsii$Proxy
@Generated(value="jsii-pacmak/1.119.0 (build 1634eac)",
date="2025-11-13T16:10:12.748Z")
@Stability(Stable)
public interface SnapshotCredentialsFromGeneratedPasswordOptions
extends software.amazon.jsii.JsiiSerializable
Options used in the
SnapshotCredentials.fromGeneratedPassword method.
Example:
Vpc vpc;
IInstanceEngine engine = DatabaseInstanceEngine.postgres(PostgresInstanceEngineProps.builder().version(PostgresEngineVersion.VER_16_3).build());
Key myKey = new Key(this, "MyKey");
DatabaseInstanceFromSnapshot.Builder.create(this, "InstanceFromSnapshotWithCustomizedSecret")
.engine(engine)
.vpc(vpc)
.snapshotIdentifier("mySnapshot")
.credentials(SnapshotCredentials.fromGeneratedSecret("username", SnapshotCredentialsFromGeneratedPasswordOptions.builder()
.encryptionKey(myKey)
.excludeCharacters("!&*^#@()")
.replicaRegions(List.of(ReplicaRegion.builder().region("eu-west-1").build(), ReplicaRegion.builder().region("eu-west-2").build()))
.build()))
.build();
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA builder forSnapshotCredentialsFromGeneratedPasswordOptionsstatic final classAn implementation forSnapshotCredentialsFromGeneratedPasswordOptions -
Method Summary
Modifier and TypeMethodDescriptionbuilder()default IKeyKMS encryption key to encrypt the generated secret.default StringThe characters to exclude from the generated password.default List<ReplicaRegion> A list of regions where to replicate this secret.Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getEncryptionKey
KMS encryption key to encrypt the generated secret.Default: - default master key
-
getExcludeCharacters
The characters to exclude from the generated password.Default: - the DatabaseSecret default exclude character set (" %+~`#$invalid input: '&'*()|[]{}:;invalid input: '<'>?!'/@\"\\")
-
getReplicaRegions
A list of regions where to replicate this secret.Default: - Secret is not replicated
-
builder
-