Created
June 18, 2012 13:31
-
-
Save yutax77/2948389 to your computer and use it in GitHub Desktop.
How to FORCE update logback's configure file
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void updateConfigure() throws JoranException { | |
LoggerContext loggerContext = (LoggerContext) LoggerFactory.getILoggerFactory(); | |
ContextInitializer ci = new ContextInitializer(loggerContext); | |
JoranConfigurator configurator = new JoranConfigurator(); | |
configurator.setContext(loggerContext); | |
loggerContext.reset(); | |
configurator.doConfigure(ci.findURLOfDefaultConfigurationFile(false)); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment