Replies: 2 comments
-
Nice one, In the second approach does it stop at synth |
Beta Was this translation helpful? Give feedback.
0 replies
-
Throwing a runtime Error will stop everything so it won't synth |
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
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Summary
There are cases where I want to add specific configurations to resources passed into constructs that I vend. I'd like to add some sort of
Error
when those configurations fail to apply. I could either add an Error Annotation or I could throw an Error. There seem to be pros and cons to each approach, so I thought I'd start a discussion.Annotations
Pros
Cons
npx cdk synth
ornpx cdk deploy
forStages
(Unless the stack id is specified in the CLI)Thrown Error
Pros
Cons
Example Code
Beta Was this translation helpful? Give feedback.
All reactions