Quantcast
Channel: Active questions tagged config - Stack Overflow
Viewing all articles
Browse latest Browse all 5056

Is there a way to move a node up the root in HOCON?

$
0
0

I'm using typesafe config and I'm looking for an easy way to allow optional overrides of properties in config files that are shared between applications.

So lets say I have 2 apps, A & B. They both make use of a module Z. They both load a shared config file 'shared.conf'.

Module Z has a property defined in it's reference.conf

z.foo=bar

I'd like to be able to

#override the property for both A & Bz.foo=zap

or

#override the property for just Aa.z.foo=zip

I know I can do this for just the 'z' prefix in the application.conf of each app. e.g.

z = ${?a.z}

but I was hoping there might be a way to move all the way to the root node. e.g.

MAGICAL_ROOT = ${?a}

Is what I'm hoping for possible?


Viewing all articles
Browse latest Browse all 5056

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>