STOP Sent from my BlackBerry device on the Rogers Wireless Network -----Original Message----- From: Kapil Anand <[EMAIL PROTECTED]>
Date: Wed, 12 Mar 2008 13:30:51 To:[email protected] Subject: WARN Unrecognized element plugin (JULReceiver) Resending after log4j mailing list registration, sorry if it is duplicate: I am trying to use JUL Receiver with log4j 1.2.15 I have following on classpath: apache-jul-log4j-bridge-1.0.0-20071030.022816-5.jar apache-log4j-component-1.0-20080219.044246-2.jar log4j-1.2.15.jar apache-log4j-extras-1.0.jar log4j.xml defines the plugin after declaring the appenders and before declaring the loggers: <plugin name="julreceiver" class="org.apache.log4j.jul.JULReceiver" /> Another strange thing is, when I switched from category to logger element, I see following warning as well: log4j:WARN The content of element type "logger" must match "(level?,appender-ref*)". I have level element defined in each logger but appender-ref is missing, since all will use the ref of root logger. In the main class of the app I also added code suggested in another post: public class RunMySpringApp { private static final Object repositorySelectorGuard = new Object(); private static final LoggerRepositoryExImpl repositoryExImpl = new LoggerRepositoryExImpl(LogManager.getLoggerRepository()); public static void main(String[] args) { // HACK FOR log4j plugins to work RepositorySelector repositorySelector = new RepositorySelector() { public LoggerRepository getLoggerRepository() { return repositoryExImpl; } }; LogManager.setRepositorySelector(repositorySelector, repositorySelectorGuard); RunSpringApp.main(args); } But I still get the WARN and all JUL logs show up on stderr/stdout in the default INFO level. (the default behavior of JUL in absence of any JUL config). Any help will be appreciated. Also: Could anyone please point me to some documentation or sample xml code that provides help on how to use JULReceiver? Would defining a top level for the JUL based classes redirect all it's children to log4j? thanks -- View this message in context: http://www.nabble.com/WARN-Unrecognized-element-plugin-%28JULReceiver%29-tp16012504p16012504.html Sent from the Log4j - Users mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
