@Stability(value=Experimental) public static final class RotationSchedule.Builder extends Object implements software.amazon.jsii.Builder<RotationSchedule>
RotationSchedule.| Modifier and Type | Method and Description |
|---|---|
RotationSchedule.Builder |
automaticallyAfter(Duration automaticallyAfter)
(experimental) Specifies the number of days after the previous rotation before Secrets Manager triggers the next automatic rotation.
|
RotationSchedule |
build() |
static RotationSchedule.Builder |
create(software.constructs.Construct scope,
String id) |
RotationSchedule.Builder |
hostedRotation(HostedRotation hostedRotation)
(experimental) Hosted rotation.
|
RotationSchedule.Builder |
rotationLambda(IFunction rotationLambda)
(experimental) A Lambda function that can rotate the secret.
|
RotationSchedule.Builder |
secret(ISecret secret)
(experimental) The secret to rotate.
|
@Stability(value=Experimental) public static RotationSchedule.Builder create(software.constructs.Construct scope, String id)
scope - This parameter is required.id - This parameter is required.RotationSchedule.Builder.@Stability(value=Experimental) public RotationSchedule.Builder automaticallyAfter(Duration automaticallyAfter)
Default: Duration.days(30)
automaticallyAfter - Specifies the number of days after the previous rotation before Secrets Manager triggers the next automatic rotation. This parameter is required.this@Stability(value=Experimental) public RotationSchedule.Builder hostedRotation(HostedRotation hostedRotation)
Default: - either `rotationLambda` or `hostedRotation` must be specified
hostedRotation - Hosted rotation. This parameter is required.this@Stability(value=Experimental) public RotationSchedule.Builder rotationLambda(IFunction rotationLambda)
Default: - either `rotationLambda` or `hostedRotation` must be specified
rotationLambda - A Lambda function that can rotate the secret. This parameter is required.this@Stability(value=Experimental) public RotationSchedule.Builder secret(ISecret secret)
If hosted rotation is used, this must be a JSON string with the following format:
{
"engine": <required: database engine>,
"host": <required: instance host name>,
"username": <required: username>,
"password": <required: password>,
"dbname": <optional: database name>,
"port": <optional: if not specified, default port will be used>,
"masterarn": <required for multi user rotation: the arn of the master secret which will be used to create users/change passwords>
}
This is typically the case for a secret referenced from an AWS::SecretsManager::SecretTargetAttachment
or an ISecret returned by the attach() method of Secret.
secret - The secret to rotate. This parameter is required.this@Stability(value=Experimental) public RotationSchedule build()
build in interface software.amazon.jsii.Builder<RotationSchedule>Copyright © 2021. All rights reserved.