I'm using logback configuration for my spring boot based RESTful service. Some of my logging configuration properties reside in Consul's KV store (like, smtp host). I'm also using "spring-cloud-starter" in my project for hystrix configuration.
For the configuration, I'm using "logback-spring.xml" so that I've access to spring context in the logback configuration via "springProperty" tag.
Now, my problem is, at the time of bootstrap, BootstrapApplicationListener is invoked which reads all the bootstrap resources (bootstrap.properties) and loads the Logging System. At this point, the Consul configurations (ConsulAutoConfiguration) have not been loaded, due to which, the required logging configuration is not found, hence, the logback is not initialized properly.
Is there a way to get the Consul configuration loaded before or during execution of BootstrapApplicationListener so that the logging system initializes properly?
Alternatively, is there any other way to just reset the logging system after the Consul properties are read?
Thanks.