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.
By clicking “Sign up for GitHub”, you agree to our
terms of service
and
privacy statement
. We’ll occasionally send you account related emails.
Already on GitHub?
Sign in
to your account
I noticed a different behavior of the property
spring.cloud.bootstrap.location
since Spring Boot 2.x
Behavior in Spring Boot 1.x:
Build in bootstrap.properties file inside the JAR
is
regarded
Specified bootstrap.properties file is regarded
Behavior in Spring Boot 2.x:
Build in bootstrap.properties file inside the JAR
is not
regarded
Specified bootstrap.properties file is regarded
Reason is that since Spring Boot 2 the behavior of the
spring.config.location configuration
has been fixed and the property
spring.cloud.bootstrap.location
works now also as desired.
See
https://github.com/spring-projects/spring-boot/wiki/Spring-Boot-2.0-Migration-Guide#configuration-location
I restored the origin behavior by adding the default search locations to the property in addition
spring.cloud.bootstrap.location=classpath:/,classpath:/config/,file:./,file:./config/,file:/my/special/search/location
It would be great to introduce also a new property
spring.cloud.bootstrap.additional-location
like the
spring.config.additional-location
.
See also
https://stackoverflow.com/questions/54204333/different-behavior-of-spring-cloud-bootstrap-location-since-spring-boot-2
I'll try to provide a pull-request in the next days for that.
Introduce property spring.cloud.bootstrap.additional-location according to spring.config.additional-location (#466)