Commit e24196b8 authored by Phillip Webb's avatar Phillip Webb

Merge branch '1.1.x'

Conflicts:
	spring-boot/src/main/java/org/springframework/boot/StartupInfoLogger.java
	spring-boot/src/main/java/org/springframework/boot/logging/logback/LogbackLoggingSystem.java
parents ca4d1f97 1ef77d7d
......@@ -17,6 +17,8 @@
package org.springframework.boot.logging.logback;
import java.net.URL;
import java.security.CodeSource;
import java.security.ProtectionDomain;
import java.util.Collections;
import java.util.HashMap;
import java.util.Map;
......@@ -146,10 +148,21 @@ public class LogbackLoggingSystem extends Slf4JLoggingSystem {
+ "implementation (%s loaded from %s). If you are using "
+ "Weblogic you will need to add 'org.slf4j' to "
+ "prefer-application-packages in WEB-INF/weblogic.xml",
factory.getClass(), factory.getClass().getProtectionDomain()
.getCodeSource().getLocation()));
factory.getClass(), getLocation(factory)));
return (LoggerContext) factory;
}
private Object getLocation(ILoggerFactory factory) {
try {
ProtectionDomain protectionDomain = factory.getClass().getProtectionDomain();
CodeSource codeSource = protectionDomain.getCodeSource();
if (codeSource != null) {
return codeSource.getLocation();
}
}
catch (SecurityException ex) {
// Unable to determine location
}
return "unknown location";
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment