-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Configuration resolver merge bug upon null component map #9931
Comments
Although the above instructions demonstrate incorrect behavior, if you explicitly provide empty map value |
To be honest I'm usually confused by this behavior. I don't think the current YAML spec 1.2.2 covers merging of two YAML documents. I believe the current behavior is a result of the internal implementation, which (if I'm not mistaken) uses koanf to merge parsed YAML files:
We could either accept it (and possibly document if it is not currently documented), or decide on another behavior and change the implementation. I wonder if I'm overthinking it or missing something. 🤔 Will take it to today's SIG. |
AFAICT, merging is unspecified anywhere; however, OTel documents three things on the main config-doc page that contributed to my expectations for this behavior.
In no scenario would I expect a |
That said, thanks for weighing in. Let me know how what the SIG thinks. |
|
The outcome of the discussion in the SIG meeting is that this is expected behavior. We might need to document this. |
#### Link to tracking issue Closes #9931
Describe the bug
Merge of two or more configurations fails when any component map is
null
. Based on my testing, I think there is a bug in the merge logic behindconfmap.Resolver.Resolve()
. Thenull
seems to be "infectious" and wipes the map for that component type.Steps to reproduce
builder-config.yaml
from Additional context to your working directory.alpha.yaml
andbeta.yaml
from Additional context to your working directory.What did you expect to see?
Success.
What did you see instead?
Failure. Specifically,
What version did you use?
See
builder-config.yaml
.What config did you use?
See
alpha.yaml
andbeta.yaml
.Environment
Additional context
builder-config.yaml:
alpha.yaml:
beta.yaml:
The text was updated successfully, but these errors were encountered: