Replies: 2 comments
-
Thanks @farski for raising the feature request. I think your points about using We try to take in popular feature requests based on 👍🏽 from the community. We will be adding this to our intake for prioritization. |
Beta Was this translation helpful? Give feedback.
0 replies
-
That linked PR doesn't have anything to do with supporting verbose tag structures. Stating it here so it won't confuse the community. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
The tagging structure that SAM tends to use (
{my_key: my_value}
) is significantly less flexible than the format than the format that many CloudFormation templates use ([{ Key: my_key, Value: my_value }]
), and it would be great if SAM allowed for using the older, more verbose format as well.I understand and appreciate that SAM generally tries to simplify the deployment of many complex resources, and allows for writing less code in many cases. In this case, though, since tagging in inherently a function designed for user-defined customization, the lack of choice to use the more verbose structure conflicts with that design intent of tagging.
As an example of where this creates an issue, there are times where I create templates and I want some tag key and tag value to be user-defined through stack parameters. Using the verbose structure of tagging, this very easy to achieve (
[{ Key: !Ref TagKey Value: !Ref TagValue }]
. Using the more compact structure, there's no way to useRef
to define the tag key.It's certainly possible in these cases to replace all SAM resources with their CloudFormation counterparts, but it's strange to have to give up all the benefits and time savings associated with SAM, just to achieve something so basic with tagging.
Given that, in nearly all cases, SAM has to translate from the compact structure to the verbose structure to create the underlying resources during transformation, it would be great if it could identify when the
Tags
property is an array rather than a map, and simply pass the tags along without transforming them in that case.Beta Was this translation helpful? Give feedback.
All reactions