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
Actually when merging a config with new values, while the path did (using ConfigDocumentFactory.withValue("not.existing.path", newValue)) not exists the output of the configuration is always in the following form:
a : { b : { c : { d : { y : 0 } } } }
// or with multiple keysa : { b : { c : { d : { y : 0 , x : 0 } } } }
However I think it might be suitable to actually configure this output to at least use a more "normalized form" like:
a.b.c.d.y = 0// ora.b.c.d.y = 0a.b.c.d.x = 0
just for readability.
The text was updated successfully, but these errors were encountered:
Well I actually would prefer to have it configurable since we would prefer to have them dotted even with multiple childs.
I would probably come up with a PR as soon as the project where we use that function needs it (probably in one/two month(s)).
We actually use it to change configuration from the console and from a web interface. and it will render it extremly non human readable once the config got missing/rewritten from the web interface.
Well
a.b = {
x=10
y=11
}
would be a improvement but I guess it's harder to do than the everything dot notation.
Configurable is a harder patch to write, but could be OK if the configuration knobs seem fairly logical and likely to all be useful. There are 1000 ways to format things, don't want to support them all, though. Would prioritize having a nice default over trying to be an arbitrary-personal-preferences formatting engine. Config knobs would maybe be something very high-level like "always flatten (no braces, only dots)" vs. "smart flatten (use dots when there's a single child)", I don't know.
I suspect both of these conventions are fairly easy to implement.
ConfigDocument is supposed to be retaining existing formatting for stuff that was not modified, of course (if I remember right at least).
Actually when merging a config with new values, while the path did (using
ConfigDocumentFactory.withValue("not.existing.path", newValue)
) not exists the output of the configuration is always in the following form:However I think it might be suitable to actually configure this output to at least use a more "normalized form" like:
just for readability.
The text was updated successfully, but these errors were encountered: