Here is a token patch to demonstrate interest in this issue...
It allows a user to turn off GeoServer-controlled logging and let the container manage the logs. I've primarily tested this with JBoss 4.0.3SP1 and log4j, however I believe it is possible to have pure Java logging by:
1. Removing LoggingStartupContextListener from the listener chain in web.xml
2. Explicitly routing Commons Logging routing to the Jdk14Logger (Acegi and Spring use Commons Logging), using commons-logging.properties in the class path.
The code follows the pattern of org.vfny.geoserver.global.GeoServerDataDirectory, defining RELINQUISH_LOGGING_CONTROL as a system property and as a web.xml context-param. It makes use of GeoServer.suppressLoggingConfiguration() which was originally designed for testing purposes only. The patch is against 1.6.4b.
I've also provided a context listener (SuppressLoggingConfigurationContextListener) that users can insert into their listener chain in web.xml – allowing a user with a stock 1.6.4b to tell GeoServer to relinquish logging control. This way, users can work around the issue now, without having to compile in a patch.
To use SuppressLoggingConfigurationContextListener, put SuppressLoggingConfigurationContextListener.class into WEB-INF/classes/org/geoserver/logging/ and modify WEB-INF/web.xml to add it to its listener list:
<listener>
<listener-class>org.geoserver.logging.SuppressLoggingConfigurationContextListener</listener-class>
</listener>
This should go after GeoserverInitStartupListener and LoggingStartupContextListener.
Here is a token patch to demonstrate interest in this issue...
It allows a user to turn off GeoServer-controlled logging and let the container manage the logs. I've primarily tested this with JBoss 4.0.3SP1 and log4j, however I believe it is possible to have pure Java logging by:
1. Removing LoggingStartupContextListener from the listener chain in web.xml
2. Explicitly routing Commons Logging routing to the Jdk14Logger (Acegi and Spring use Commons Logging), using commons-logging.properties in the class path.
The code follows the pattern of org.vfny.geoserver.global.GeoServerDataDirectory, defining RELINQUISH_LOGGING_CONTROL as a system property and as a web.xml context-param. It makes use of GeoServer.suppressLoggingConfiguration() which was originally designed for testing purposes only. The patch is against 1.6.4b.
I've also provided a context listener (SuppressLoggingConfigurationContextListener) that users can insert into their listener chain in web.xml – allowing a user with a stock 1.6.4b to tell GeoServer to relinquish logging control. This way, users can work around the issue now, without having to compile in a patch.
To use SuppressLoggingConfigurationContextListener, put SuppressLoggingConfigurationContextListener.class into WEB-INF/classes/org/geoserver/logging/ and modify WEB-INF/web.xml to add it to its listener list:
<listener>
<listener-class>org.geoserver.logging.SuppressLoggingConfigurationContextListener</listener-class>
</listener>
This should go after GeoserverInitStartupListener and LoggingStartupContextListener.