by dmitriid · 4y ago · 0 comments
Edit: Well, the whole "no idea how to configure a thing" is the common refrain of any and all Java frameworks. Pray that your IDE has enough smarts to autocomplete something for you.
I don't think it should be a complicated problem. On startup, the framework should be able to tell you in a log file, what are all the places it read each configuration item from, and which value was finally used.
I am big fan of design philosophy where the computer tells you how it understood your commands (this includes configuration), before it does a thing.
14 seems like a lot, but in reality you'll like use only a couple of layers in a production deployment.
The reason there's so many is that list is exhaustive and includes sources only relevant to development and testing, as well there are a number of ways you may want to inject environment specific configuration values (command line flags, system properties, jndi, environment variables, etc..), you would normally just pick the one that made sense for your deployment environment.
https://docs.spring.io/spring-boot/docs/current/reference/ht...
I had to work with SAP Hybris a year or two ago. My IDE was not smart enough. Well actually I spent a good number of days trying to configure my IDE to be able to work properly with Hybris. I failed.
What a mess