Turar
Turar

Reputation: 1561

Spring Config Server reloading native properties

Are native properties supposed to be reloading dynamically? E.g. if I have:

spring.profiles.active=native
spring.cloud.config.server.native.searchLocations=classpath:/config-native

And a file called sample.properties with:

example-property="Hello from config server"

And then I change example-property value to something else, and do another GET against Config Server without restarting it, I'm still seeing the old value displayed.

Is this expected behavior? I'm able to see updated property value if I do the same with non-native (git) setup.

Upvotes: 0

Views: 175

Answers (1)

spencergibb
spencergibb

Reputation: 25147

I have a suspicion it has to do with classpath:/. If it were file:/ it would always work. With classpath, things might get cached with a classloader.

Upvotes: 1

Related Questions