[Feature Request]: Default Resolver for Variables
- Dominant language
- Java
- Stars
- 1.5k
- Forks
- 476
- Avg merge
- 18h 32m
- Merged PRs (30d)
- 216
Description
### What would you like to happen?
It would be very useful to implement a default resolver. This resolver would allow specifying a default value to use in case a variable is not set.
Examples:
- `${my-var}` not set → `#{default-resolver:${my-var}:123}` ⇒ 123
- `${my-var}` set to 0 → `#{default-resolver:${my-var}:123}` ⇒ 0
Default value can itself be a variable:
- `#{default-resolver:${my-var}:${my-var-default}}`
### Issue Priority
Priority: 2
### Issue Component
Component: Hop Config, Component: Other
Contributor guide
Research direction
Start in the Hop Config variable-resolution entry points and trace how expressions such as `${my-var}` are currently handled. Define tests for an unset variable, a value of 0, and a variable used as the default; done means the requested `default-resolver` examples resolve to the documented values.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- tooling
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100