Skip to content

(aws_events_targets): Confusing installLatestAwsSdk warning #23956

@mvs5465

Description

@mvs5465

Describe the issue

We are using the aws_events_targets module and this appears to be creating a custom resource. Specifically working with cloudtrail events for the onEvent static method: https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_cloudtrail.Trail.html#static-onwbreventscope-id-options

When compiling, there is a warning:

installLatestAwsSdk was not specified, and defaults to true. You probably do not want this. Set the global context flag '@aws-cdk/customresources:installLatestAwsSdkDefault' to false to switch this behavior off project-wide, or set the property explicitly to true if you know you need to call APIs that are not in Lambda's built-in SDK version.

What is the intended way to set this flag? Is this something the user should set? I see this PR from 3 weeks ago saying the default value is now false: #23591

Links

#23591

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions