Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(core):
serviceTimeout
for CustomResource
does not work with t…
…oken (#33541) ### Issue # (if applicable) Closes #33513. ### Reason for this change The `serviceTimeout` for `CustomResource` does not work with token. The way the token is handled is wrong, and the `isUnresolved` method that the `Duration` type has should be used. ### Description of changes Use the `props.serviceTimeout.isUnresolved()`. Also add a doc that the token must be specified in `Duration.seconds()` since it is converted by `toSeconds` internally. (Because it is a token and unknown MINUTES value cannot be converted to SECONDS. This is due to the token mechanism.) see: https://github.com/go-to-k/aws-cdk/blob/75e52619cd09f363882ff62561a53cd5cd79ab30/packages/aws-cdk-lib/core/lib/custom-resource.ts#L169 https://github.com/go-to-k/aws-cdk/blob/75e52619cd09f363882ff62561a53cd5cd79ab30/packages/aws-cdk-lib/core/lib/duration.ts#L332 ### Describe any new or updated permissions being added ### Description of how you validated changes Unit tests. ### Checklist - [x] My code adheres to the [CONTRIBUTING GUIDE](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md) and [DESIGN GUIDELINES](https://github.com/aws/aws-cdk/blob/main/docs/DESIGN_GUIDELINES.md) ---- *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
- Loading branch information