aws-cloudformation / aws-cloudformation-resource-providers-rds

The CloudFormation Resource Provider Package For Amazon Relational Database Service
https://aws.amazon.com/rds/
Apache License 2.0
26 stars 42 forks source link

[Common][All] Update soft failure on stack level tags to `Unauthorize… #461

Closed moataz-mhmd closed 1 year ago

moataz-mhmd commented 1 year ago

Description of changes:

In order to maintain compatibility with older versions, we used to overlook the AccessDenied exception when a customer lacked the permission to add stack level tags. This PR aims to rectify this behavior by following to the latest CloudFormation guidelines and instead throwing an UnauthorizedTaggingOperation error code.

However, we still have the tagging logic in place to distinguish between access denied for resource tags and access denied for stack level tags. Once CloudFormation confirms that it is safe to convert UnauthorizedTaggingOperation to the regular AccessDenied error code, we can safely remove all the logic related to tag error management and the safeCreate mechanism.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.