tag:blogger.com,1999:blog-13556721.post3915111947311293909..comments2023-05-29T18:53:18.727+09:30Comments on The Buttso Blathers: Using SLF4J with WebLogic Server LoggingButtsohttp://www.blogger.com/profile/03968454565733104381noreply@blogger.comBlogger3125tag:blogger.com,1999:blog-13556721.post-34092342358048024782013-10-10T17:34:56.448+10:302013-10-10T17:34:56.448+10:30I've got some pain with the WLS 12. If you dep...I've got some pain with the WLS 12. If you deploy an EAR, this might help:<br />place a file weblogic-application.xml into the folder META-INF with this content:<br /><br /><!DOCTYPE weblogic-application PUBLIC '-//BEA Systems, Inc.//DTD WebLogic Application 8.1.0//EN' 'http://www.bea.com/servers/wls810/dtd/weblogic-application_2_0.dtd'><br><weblogic-application><br> <prefer-application-packages><br> <package-name>org.slf4j.*</package-name><br> </prefer-application-packages><br></weblogic-application><br><br /><br />This tells the Weblogic Server to resolve every reference to the package org.slf4j with the deployed application prior to its own libraries.Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-13556721.post-44631917109627404232012-05-08T22:56:59.411+09:302012-05-08T22:56:59.411+09:30For all you weblogic 12c users. Since weblogic 12c...For all you weblogic 12c users. Since weblogic 12c slf4j binding for jdk is loaded as a module at server startup. This will make it easier for you if you're trying to use the standard weblogic server log facilities.<br /><br />But, it will make your life harder if you want another slf4j binding to be used, which is what I'm trying :)tim vissershttp://yourweblogic.wordpress.comnoreply@blogger.comtag:blogger.com,1999:blog-13556721.post-78468474687467749102011-07-08T22:47:05.461+09:302011-07-08T22:47:05.461+09:30Too bad you didn't write this blog, oh, about ...Too bad you didn't write this blog, oh, about a year ago. I ended up using log4j because it gave us more felxibility for configuration. The configuration is very similar, but what we found out was that WL includes an older version of log4j. When you launch the console web app, it must have used this older log4j.jar, resulting in exceptions when using the ServerLoggingAppender. Initially our solution was to include the log4j.properties file as a jar in the domain/lib folder (the order in which log4j looks for its configuration file located the one included with the console web app before the one in lib). Eventually we went with an admin/managed setup and left the admin server (where the console app deploys) using java.util.logging.wpragerhttps://www.blogger.com/profile/07569925319579455865noreply@blogger.com