-
Notifications
You must be signed in to change notification settings - Fork 41.2k
logback-spring.xml reloading not working for springProfile in 1.4.2.RELEASE #7955
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
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
Comments
Sadly, I think we may need to document this as a limitation. To support private void performXMLConfiguration(LoggerContext lc, URL mainConfigurationURL) {
JoranConfigurator jc = new JoranConfigurator();
jc.setContext(context);
StatusUtil statusUtil = new StatusUtil(context);
List<SaxEvent> eventList = jc.recallSafeConfiguration();
URL mainURL = ConfigurationWatchListUtil.getMainWatchURL(context);
lc.reset();
long threshold = System.currentTimeMillis();
try {
jc.doConfigure(mainConfigurationURL);
if (statusUtil.hasXMLParsingErrors(threshold)) {
fallbackConfiguration(lc, eventList, mainURL);
}
} catch (JoranException e) {
fallbackConfiguration(lc, eventList, mainURL);
}
} |
I've just noticed that this is a duplicate of #5611 |
My apologies for commenting on a closed ticket, but shouldn't this limitation/RFE be reported to logback? (I can't find it on their JIRA) |
@extraneu I am not aware this has been reported but feel free to do so. |
Hi |
I was expecting scan="true" with scanPeriod="5 seconds" to work with logback configuration in SpringBoot 1.4.2.RELEASE
The error I get on updating a logger level inside is
Same goes for springProperty
Without springProfile and springProperty scan happens as expected, but only when changes done in target/classes/logback-spring.xml and not in src/main/resources/logback-spring.xml
Without setting scan, springProfile working as expected.
Maven is being used for this SpringBoot Web app.
The text was updated successfully, but these errors were encountered: