aws synthetics: cleanup canary resources
- Dominant language
- TypeScript
- Stars
- 12.9k
- Forks
- 4.6k
- Avg merge
- 1d 19h
- Merged PRs (30d)
- 71
Description
### Describe the feature
Upon stack deletion I noticed that `Canary` constructs left behind not only lambda functions, but S3 buckets (containing screenshots) as well. I would have expected all resources created by the canary to be deleted automatically, or at least having a `retention` option on the `Canary` construct.
### Use Case
On deletion of a `Canary` construct, all resources (lambdas, s3 buckets,…) created for it should be deleted by default.
### Proposed Solution
I believe #26580 went for a solution approach, but is limited to the lambda function for the canary. Maybe this can be extended to all resources, or even made the default instead of a separate `cleanup` configuration?
### Other Information
I saw similar efforts in #18448, which added lambda deletion but did not resolve s3 bucket deletion to my knowledge.
### Acknowledgements
- [ ] I may be able to implement this feature request
- [ ] This feature might incur a breaking change
### CDK version used
2.130.0
### Environment details (OS name and version, etc.)
irrelevant
Contributor guide
Research direction
Start by reviewing the Canary construct and the cleanup approaches discussed in issues #26580 and #18448. Determine how all canary-created resources, including Lambda functions and S3 buckets, should be handled on stack deletion, and whether cleanup should be the default or a retention option; done means the intended deletion behavior is implemented without leaving those resources behind.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, typescript
- Domain
- cloud, infrastructure
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100