-
Notifications
You must be signed in to change notification settings - Fork 4.5k
Closed
Labels
@aws-cdk/aws-ssmRelated to AWS Systems ManagerRelated to AWS Systems ManagerbugThis issue is a bug.This issue is a bug.closed-for-stalenessThis issue was automatically closed because it hadn't received any attention in a while.This issue was automatically closed because it hadn't received any attention in a while.effort/mediumMedium work item – several days of effortMedium work item – several days of effortfeature-requestA feature should be added or improved.A feature should be added or improved.p1response-requestedWaiting on additional info and feedback. Will move to "closing-soon" in 7 days.Waiting on additional info and feedback. Will move to "closing-soon" in 7 days.
Description
Describe the feature
When using ssm.StringParameter.valueFromLookup, it crashes (not sure, but error is not catchable), when the parameter doesn't exist. It makes it unusable for scenarios with a fallback parameter.
Use Case
For a short-lived infrastructure it's both important to be configurable (create a parameter & deploy), and have a nice fallback value (just deploy). SSM parameter is a perfect solution, since it can be resolved at synth time. It's very unfortunate, that currently it's impossible not to crash, when the value doesn't exist.
Proposed Solution
Return undefined, instead of crashing, or expose a better API, with multiple fallback parameter names to check.
Other Information
This issue was also discussed here: #7259
Acknowledgements
- I may be able to implement this feature request
- This feature might incur a breaking change
CDK version used
2
Environment details (OS name and version, etc.)
Any
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
@aws-cdk/aws-ssmRelated to AWS Systems ManagerRelated to AWS Systems ManagerbugThis issue is a bug.This issue is a bug.closed-for-stalenessThis issue was automatically closed because it hadn't received any attention in a while.This issue was automatically closed because it hadn't received any attention in a while.effort/mediumMedium work item – several days of effortMedium work item – several days of effortfeature-requestA feature should be added or improved.A feature should be added or improved.p1response-requestedWaiting on additional info and feedback. Will move to "closing-soon" in 7 days.Waiting on additional info and feedback. Will move to "closing-soon" in 7 days.