-
Notifications
You must be signed in to change notification settings - Fork 3.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(logs): delete associated log group when stack is deleted (#21113)
---- Motivation: The log group created by LogRetention lingers after the stack is deleted. This commit allows users to choose whether to retain or destroy associated logs of the deleted stack. Use case: To avoid having hundreds of dead log groups after the stack is deleted. most salient design aspects: Added an enum LogDeletionPolicy and set LogDeletionPolicy in the LogRetetion custom resource. Added an API deleteLogGroup and added an event 'Delete' to the handler of LogRetetion to delete the log group. closes [#11549](#11549) ### All Submissions: * [x] Have you followed the guidelines in our [Contributing guide?](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md) ### Adding new Unconventional Dependencies: * [ ] This PR adds new unconventional dependencies following the process described [here](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md/#adding-new-unconventional-dependencies) ### New Features * [x] Have you added the new feature to an [integration test](https://github.com/aws/aws-cdk/blob/main/INTEGRATION_TESTS.md)? * [x] Did you use `yarn integ` to deploy the infrastructure and generate the snapshot (i.e. `yarn integ` without `--dry-run`)? *By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
- Loading branch information
1 parent
0767873
commit 2bdd504
Showing
27 changed files
with
1,326 additions
and
495 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
40 changes: 0 additions & 40 deletions
40
...s-cdk/aws-logs/test/cdk-integ.out.expose-metric/aws-cdk-expose-metric-integ.template.json
This file was deleted.
Oops, something went wrong.
40 changes: 0 additions & 40 deletions
40
packages/@aws-cdk/aws-logs/test/cdk-integ.out.expose-metric/manifest.json
This file was deleted.
Oops, something went wrong.
119 changes: 0 additions & 119 deletions
119
packages/@aws-cdk/aws-logs/test/cdk-integ.out.expose-metric/tree.json
This file was deleted.
Oops, something went wrong.
28 changes: 0 additions & 28 deletions
28
...cdk/aws-logs/test/cdk-integ.out.metricfilter.lit/aws-cdk-metricfilter-integ.template.json
This file was deleted.
Oops, something went wrong.
1 change: 0 additions & 1 deletion
1
packages/@aws-cdk/aws-logs/test/cdk-integ.out.metricfilter.lit/cdk.out
This file was deleted.
Oops, something went wrong.
34 changes: 0 additions & 34 deletions
34
packages/@aws-cdk/aws-logs/test/cdk-integ.out.metricfilter.lit/manifest.json
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.