Spring Cloud Config Server has magical property
searchPaths that magically alter search order of
YAML file in Git repository. YAML file name conventions and config file layout itself are magic.
Maintaining code with checks first and keeping all on a single level can be tricky because language designers don't worried about such use case.
Now is time for some Java interview questions.