How to pass configuration through yaml file to a running spring boot application so that there is no need of rebuilding the application and changes are reflected while the application is runnig?
Asked
Active
Viewed 913 times
1
-
You mean changing properties at runtime? – jdickel Aug 11 '19 at 09:16
-
For that you need to use spring devtools dependencies – GnanaJeyam Aug 11 '19 at 09:26
-
@jdickel yes exactly, do you know that is done in spring boot. – harsh garg Aug 11 '19 at 09:45
-
@gnanajeyam95 can we pass configurations using yaml file if we make use of spring devtools dependencies. – harsh garg Aug 11 '19 at 09:46
-
Possible duplicate of [How to hot-reload properties in Java EE and Spring Boot?](https://stackoverflow.com/questions/52594764/how-to-hot-reload-properties-in-java-ee-and-spring-boot) – Aug 11 '19 at 11:02
2 Answers
1
I think this can help you:
-
I guess there is a way to pass yaml conifguration file during time, but how exactly it's done is my question. – harsh garg Aug 11 '19 at 09:43
-
https://stackoverflow.com/questions/52594764/how-to-hot-reload-properties-in-java-ee-and-spring-boot – Aug 11 '19 at 11:01
0
Take a look at Spring Boot Cloud Config. It allows you to manage your config files centralized and has the ability to push new configurations to the connected applications.

jdickel
- 1,437
- 1
- 11
- 21
-
If I don't want to push the configurations from the external congif-server, instead my configuration file is residing in my project itself so is there any way I can load this file during run time. – harsh garg Aug 11 '19 at 10:16