diff options
| author | Alex Rudyy <orudyy@apache.org> | 2014-03-21 12:44:50 +0000 |
|---|---|---|
| committer | Alex Rudyy <orudyy@apache.org> | 2014-03-21 12:44:50 +0000 |
| commit | f34e698b3beb0aa5810adff8bc101b37aa6eb2d2 (patch) | |
| tree | b7be4456f636f11f817cb50073e90c22920c968f /qpid/java/broker-core/src | |
| parent | cdfa97831a3653390fb11baf69d8015af84311bb (diff) | |
| download | qpid-python-f34e698b3beb0aa5810adff8bc101b37aa6eb2d2.tar.gz | |
QPID-5048: dby profiles, bdb test deps and config for perftests-systests & bdbstore-systests and a fix for clean between test runs
Patch supplied by Andrew MacBean <andymacbean@gmail.com>
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1579935 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/java/broker-core/src')
| -rw-r--r-- | qpid/java/broker-core/src/main/java/org/apache/qpid/server/Broker.java | 19 |
1 files changed, 15 insertions, 4 deletions
diff --git a/qpid/java/broker-core/src/main/java/org/apache/qpid/server/Broker.java b/qpid/java/broker-core/src/main/java/org/apache/qpid/server/Broker.java index ffa1d65ec2..0ec6a31253 100644 --- a/qpid/java/broker-core/src/main/java/org/apache/qpid/server/Broker.java +++ b/qpid/java/broker-core/src/main/java/org/apache/qpid/server/Broker.java @@ -29,6 +29,7 @@ import java.util.List; import java.util.Properties; import java.util.Set; +import org.apache.log4j.LogManager; import org.apache.log4j.Logger; import org.apache.log4j.PropertyConfigurator; import org.apache.qpid.server.configuration.ConfigurationEntryStore; @@ -41,7 +42,6 @@ import org.apache.qpid.server.logging.messages.BrokerMessages; import org.apache.qpid.server.registry.ApplicationRegistry; import org.apache.qpid.server.registry.IApplicationRegistry; import org.apache.qpid.server.security.SecurityManager; -import org.apache.qpid.server.security.auth.TaskPrincipal; import javax.security.auth.Subject; @@ -52,6 +52,7 @@ public class Broker private volatile Thread _shutdownHookThread; private volatile IApplicationRegistry _applicationRegistry; private EventLogger _eventLogger; + private boolean _configuringOwnLogging = false; protected static class InitException extends RuntimeException { @@ -71,11 +72,20 @@ public class Broker } finally { - if (_applicationRegistry != null) + try { - _applicationRegistry.close(); + if (_applicationRegistry != null) + { + _applicationRegistry.close(); + } + } + finally + { + if (_configuringOwnLogging) + { + LogManager.shutdown(); + } } - } } @@ -166,6 +176,7 @@ public class Broker private void configureLogging(File logConfigFile, int logWatchTime) throws InitException, IOException { + _configuringOwnLogging = true; if (logConfigFile.exists() && logConfigFile.canRead()) { _eventLogger.message(BrokerMessages.LOG_CONFIG(logConfigFile.getAbsolutePath())); |
