Tom,
Do not extend the Category class and your problems will go away. Extending the category class is (almost) always a bad idea. Regards, Ceki At 17:11 29.01.2002 -0500, you wrote: >Hello, > >I'm not sure if this is the correct place to ask this question, but if not, >I apologize. > >Can anyone assist me in getting log4j to work properly with JBoss 2.4.3? We >are extending the Category class with a our own. This works fine as a >standalone java program. We are having problems, however, getting it to work >with JBoss. > >The log4j.properties file looks like the following: > >######################################################## ># A log4j properties file suitable for replacing the ># default JBoss ConsoleLogging & FileLogging mbeans. > ># Set the JBossCategoryFactory as the default CategoryFactory >log4j.categoryFactory=org.jboss.logging.log4j.JBossCategory$JBossCategoryFac >tory > >log4j.rootCategory=DEBUG, Default, Console > >### The server.log file appender >log4j.appender.Default=org.apache.log4j.FileAppender >log4j.appender.Default.File=../log/server.log >log4j.appender.Default.layout=org.apache.log4j.PatternLayout ># Use the default JBoss format >log4j.appender.Default.layout.ConversionPattern=[%c{1}] %m%n ># Truncate if it aleady exists. >log4j.appender.Default.Append=false >#Example of turning off logging for a category. Uncomment to turn off. >#log4j.category.DefaultDS=FATAL > >### The console appender >log4j.appender.Console=org.jboss.logging.log4j.ConsoleAppender >log4j.appender.Console.Threshold=INFO >log4j.appender.Console.layout=org.apache.log4j.PatternLayout >log4j.appender.Console.layout.ConversionPattern=[%c{1}] %m%n > ># Example of only showing INFO msgs for any categories under org.jboss.util >#log4j.category.org.jboss.util=INFO > ># An example of enabling the custom TRACE level priority that is used ># by the JBoss internals to diagnose low level details. This example ># turns on TRACE level msgs for the org.jboss.ejb.plugins package and its ># subpackages. This will produce A LOT of logging output. >#log4j.category.org.jboss.ejb.plugins=TRACE#org.jboss.logging.log4j.TracePri >ority > > > ># EJBEnterprise Changes FOLLOW.......... > ># A log4j properties file suitable for replacing the ># default JBoss ConsoleLogging & FileLogging mbeans. > ># Set the JBossCategoryFactory as the default CategoryFactory >#log4j.rootCategory=DEBUG > ># Following lines have been added for EJBUserCategory > ># set up the category factory >log4j.categoryFactory=com.ejbenterprise.util.logging.EJBUserCategoryFactory >log4j.factory.ejbuser=Greg > ># set up the appender >log4j.appender.EJBUserAppender=org.apache.log4j.FileAppender >log4j.appender.EJBUserAppender.File=FilteredUser.log >log4j.appender.EJBUserAppender.layout=com.ejbenterprise.util.logging.EJBUser >PatternLayout >log4j.appender.EJBUserAppender.layout.ConversionPattern=User: %u [%c{1}] >%m%n >log4j.appender.EJBUserAppender.Append=false > > ># set up logging for a class >log4j.category.com.ejbenterprise.util.server=DEBUG, EJBUserAppender >################################################## > > >Now, when the server starts, we are getting ClassNotFoundException for core >log4j classes like Category, Priority etc. Does anybody know why this >happens and what the correct way to configure JBoss / log4j is? > >-Tom > > >-- >To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> >For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> -- Ceki Gülcü -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>