diff options
| author | Robert Gemmell <robbie@apache.org> | 2009-08-16 20:32:47 +0000 |
|---|---|---|
| committer | Robert Gemmell <robbie@apache.org> | 2009-08-16 20:32:47 +0000 |
| commit | cf23e7282bfc1347c4630563c620e847a4c963a8 (patch) | |
| tree | b27052d8e8da12d3b9b32fef3d431c89ea80bb14 /java/broker/bin/qpid-server | |
| parent | a0fdaab822f22d8c505edae36ca15d7b1999c3c9 (diff) | |
| download | qpid-python-cf23e7282bfc1347c4630563c620e847a4c963a8.tar.gz | |
QPID-2051: Update startup scripts to disable the Log4J default initialisation process. Add QpidLog4JConfigurator that validates the XML file before allowing it to be applied. Alter startup behaviour to shut the broker down if the specified log4j XML file is present present but invalid. Uses the -Damqj.logging.level(defaults to info) with the log4j.properties file in the broker jar if the XML file is not found.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@804765 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'java/broker/bin/qpid-server')
| -rwxr-xr-x | java/broker/bin/qpid-server | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/java/broker/bin/qpid-server b/java/broker/bin/qpid-server index e5a9e998e2..7482ad63ef 100755 --- a/java/broker/bin/qpid-server +++ b/java/broker/bin/qpid-server @@ -23,6 +23,12 @@ if [ -z "$QPID_HOME" ]; then export PATH=${PATH}:${QPID_HOME}/bin fi +if [ -z "$QPID_LOG4J_SETTINGS" ]; then + # Disable the Log4J default initialization process, allowing the broker to + # perform the configuration using etc/log4j.xml + QPID_LOG4J_SETTINGS="-Dlog4j.defaultInitOverride=true" +fi + # Set classpath to include Qpid jar with all required jars in manifest QPID_LIBS=$QPID_HOME/lib/qpid-all.jar:$QPID_HOME/lib/bdbstore-launch.jar @@ -34,6 +40,6 @@ export JAVA=java \ QPID_CLASSPATH=$QPID_LIBS \ QPID_RUN_LOG=2 -QPID_OPTS="$QPID_OPTS -Damqj.read_write_pool_size=32" +QPID_OPTS="$QPID_OPTS $QPID_LOG4J_SETTINGS -Damqj.read_write_pool_size=32" . qpid-run org.apache.qpid.server.Main "$@" |
