You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I created iam role with iam.Role resource and used built-in Tag aspect to tag roles as below: aws_cdk.Tags.of(role1).add("CustomID", "11112345")
I also created an aspect to deal with roles based on the value of tag CustomID.
But in my visit function, I could not get any tag value. node.tags.tag_values() return empty list {}
When I changed the tagging method by creating iam.CfnRole resource with tags property, my visit function successfully detected the tag value.
The problem here is the sequence/order of aspects being called. Obviously, when my aspect was called, the tag aspect had not been called and no tag was associated with the resources at the time.
I wonder whether there's a way to define dependon in aspect, so that I can ensure some aspects being called after another one.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I created iam role with iam.Role resource and used built-in Tag aspect to tag roles as below:
aws_cdk.Tags.of(role1).add("CustomID", "11112345")
I also created an aspect to deal with roles based on the value of tag CustomID.
But in my visit function, I could not get any tag value.
node.tags.tag_values()
return empty list {}When I changed the tagging method by creating iam.CfnRole resource with tags property, my visit function successfully detected the tag value.
The problem here is the sequence/order of aspects being called. Obviously, when my aspect was called, the tag aspect had not been called and no tag was associated with the resources at the time.
I wonder whether there's a way to define dependon in aspect, so that I can ensure some aspects being called after another one.
Beta Was this translation helpful? Give feedback.
All reactions