@Stability(value=Experimental) public static final class AwsCustomResource.Builder extends Object implements software.amazon.jsii.Builder<AwsCustomResource>
AwsCustomResource.| Modifier and Type | Method and Description |
|---|---|
AwsCustomResource |
build() |
static AwsCustomResource.Builder |
create(software.constructs.Construct scope,
String id) |
AwsCustomResource.Builder |
functionName(String functionName)
(experimental) A name for the Lambda function implementing this custom resource.
|
AwsCustomResource.Builder |
installLatestAwsSdk(Boolean installLatestAwsSdk)
(experimental) Whether to install the latest AWS SDK v2.
|
AwsCustomResource.Builder |
logRetention(RetentionDays logRetention)
(experimental) The number of days log events of the Lambda function implementing this custom resource are kept in CloudWatch Logs.
|
AwsCustomResource.Builder |
onCreate(AwsSdkCall onCreate)
(experimental) The AWS SDK call to make when the resource is created.
|
AwsCustomResource.Builder |
onDelete(AwsSdkCall onDelete)
(experimental) The AWS SDK call to make when the resource is deleted.
|
AwsCustomResource.Builder |
onUpdate(AwsSdkCall onUpdate)
(experimental) The AWS SDK call to make when the resource is updated.
|
AwsCustomResource.Builder |
policy(AwsCustomResourcePolicy policy)
(experimental) The policy that will be added to the execution role of the Lambda function implementing this custom resource provider.
|
AwsCustomResource.Builder |
resourceType(String resourceType)
(experimental) Cloudformation Resource type.
|
AwsCustomResource.Builder |
role(IRole role)
(experimental) The execution role for the Lambda function implementing this custom resource provider.
|
AwsCustomResource.Builder |
timeout(Duration timeout)
(experimental) The timeout for the Lambda function implementing this custom resource.
|
@Stability(value=Experimental) public static AwsCustomResource.Builder create(software.constructs.Construct scope, String id)
scope - This parameter is required.id - This parameter is required.AwsCustomResource.Builder.@Stability(value=Experimental) public AwsCustomResource.Builder policy(AwsCustomResourcePolicy policy)
The custom resource also implements iam.IGrantable, making it possible
to use the grantXxx() methods.
As this custom resource uses a singleton Lambda function, it's important to note the that function's role will eventually accumulate the permissions/grants from all resources.
policy - The policy that will be added to the execution role of the Lambda function implementing this custom resource provider. This parameter is required.thisPolicy.fromSdkCalls@Stability(value=Experimental) public AwsCustomResource.Builder functionName(String functionName)
Default: - AWS CloudFormation generates a unique physical ID and uses that ID for the function's name. For more information, see Name Type.
functionName - A name for the Lambda function implementing this custom resource. This parameter is required.this@Stability(value=Experimental) public AwsCustomResource.Builder installLatestAwsSdk(Boolean installLatestAwsSdk)
The installation takes around 60 seconds.
Default: true
installLatestAwsSdk - Whether to install the latest AWS SDK v2. Allows to use the latest API calls documented at https://docs.aws.amazon.com/AWSJavaScriptSDK/latest/index.html. This parameter is required.this@Stability(value=Experimental) public AwsCustomResource.Builder logRetention(RetentionDays logRetention)
Default: logs.RetentionDays.INFINITE
logRetention - The number of days log events of the Lambda function implementing this custom resource are kept in CloudWatch Logs. This parameter is required.this@Stability(value=Experimental) public AwsCustomResource.Builder onCreate(AwsSdkCall onCreate)
Default: - the call when the resource is updated
onCreate - The AWS SDK call to make when the resource is created. This parameter is required.this@Stability(value=Experimental) public AwsCustomResource.Builder onDelete(AwsSdkCall onDelete)
Default: - no call
onDelete - The AWS SDK call to make when the resource is deleted. This parameter is required.this@Stability(value=Experimental) public AwsCustomResource.Builder onUpdate(AwsSdkCall onUpdate)
Default: - no call
onUpdate - The AWS SDK call to make when the resource is updated. This parameter is required.this@Stability(value=Experimental) public AwsCustomResource.Builder resourceType(String resourceType)
Default: - Custom::AWS
resourceType - Cloudformation Resource type. This parameter is required.this@Stability(value=Experimental) public AwsCustomResource.Builder role(IRole role)
This role will apply to all AwsCustomResource
instances in the stack. The role must be assumable by the
lambda.amazonaws.com service principal.
Default: - a new role is created
role - The execution role for the Lambda function implementing this custom resource provider. This parameter is required.this@Stability(value=Experimental) public AwsCustomResource.Builder timeout(Duration timeout)
Default: Duration.minutes(2)
timeout - The timeout for the Lambda function implementing this custom resource. This parameter is required.this@Stability(value=Experimental) public AwsCustomResource build()
build in interface software.amazon.jsii.Builder<AwsCustomResource>Copyright © 2021. All rights reserved.