-
1. Re: Implementing EAR based logging
starksm64 Sep 26, 2004 9:01 AM (in response to tkrug0210)Which of the various techniques described in the loggins page have you tried? This page has been updated since you originally posted.
http://www.jboss.org/wiki/Wiki.jsp?page=Logging -
2. Re: Implementing EAR based logging
tkrug0210 Sep 27, 2004 3:26 AM (in response to tkrug0210)I checked classload scoping with 3.2.5 and 4.0 (default config). I also deployed the log4j.war from the example, the log data get logged in the server.log....... Same with JBoss 4.0
What happens is that Jboss seems to try some reflections and throws MethodNotFound Exceptions and ReflectionExceptions on the BaseModelMBean of org.apache.commons.modeler.
I have the Apache Commons and the log4j Jar's in my classpath (WEB-INF\LIB, an own logFactory with commons-logging.propertiesorg.apache.commons.logging.LogFactory=de.sparkasseninformatik.common.logger.SiLogFactory
and the log4j.properties in WEB-INF\Classes.
I read in another post about a bug in 3.2.5 where the classpath is at servlet init time not available, which you stated is fixed in 3.2.6RC1. Could that be the problem? -
3. Re: Implementing EAR based logging
tkrug0210 Sep 27, 2004 3:55 AM (in response to tkrug0210)I packaged the log4j.war in an ear and got some more information
2004-09-27 09:52:45,598 WARN [org.jboss.deployment.DeploymentInfo] Only the root deployment can set the loader repository, ignoring config=LoaderRepositoryConfig (repositoryName: log4j.test:loader=log4j.war, repositoryClassName: org.jboss.mx.loading.HeirarchicalLoaderRepository3, configParserClassName: org.jboss.mx.loading.HeirarchicalLoaderRepository3ConfigParser, repositoryConfig: java2ParentDelegation=false)
Thomas -
4. Re: Implementing EAR based logging
visionet Oct 12, 2004 5:50 AM (in response to tkrug0210)Hi,
did you get any solution for your poblem? Since I have the same problem, I would be glad to know how you solved it.
I am trying to set up logging for different applications. Meaning, I want for some applications that they log in a seperate loggingfile then the main server.log.
Thank you very much for sharing your experience.
regards
Emanuel Elhardt
elhardt(a)visionet.de -
5. Re: Implementing EAR based logging
scottsadlo Feb 23, 2005 12:36 PM (in response to tkrug0210)tkrug0210's code listing has points to the answer. If you read through this
http://www.jboss.org/wiki/Wiki.jsp?page=ClassLoadingConfiguration you should find that:Only the top level deployment may specify scoping. If you have an ear, containing other modules, only scoping specified in the ear META-INF/jboss-app.xml has any effect. This applies for any other deployment sitting in the deploy directory which contains other types of deployments. If a sar contains other deployments, only the sar META-INF/jboss-service.xml scoping has any effect.
This works for me BUT i have to remove common-logging.jar from my ear. Does anyone know of a way to get around custom tailoring the list of jars in an ear just to satisfy the JBoss CL?