
Hi, I have an ear file deployed to Glassfish (v.3.1.1) and cannot get the logback.xml to be loaded. I have bundled it in the ear in the META-INF directory. Where should it be located? Thanks!

sdoca wrote:
I have an ear file deployed to Glassfish (v.3.1.1) and cannot get the logback.xml to be loaded. I have bundled it in the ear in the META-INF directory. Where should it be located?
See http://hwellmann.blogspot.de/2010/05/glassfish-logging-with-slf4j.html for global configuration. Using Maven for each EAR you can deploy the logback.xml within. It has to be under ~/{project}/src/main/resources. I use JoranConfigurator to load/configure it for each EAR. -- View this message in context: http://old.nabble.com/How-to-load-logback.xml-from-ear--tp33696845p33699321.... Sent from the Logback User mailing list archive at Nabble.com.

I ended up doing the following: 1. Create a new folder directly under the EAR folder. For example, create a new folder named "classes" --> MyEar/classes 2. Place your logback.xml file in this new folder: MyEar/classes/logback.xml 3. In your WAR file's MANIFEST.MF file, add this new folder to the classpath: Manifest-Version: 1.0 Class-Path: classes Thanks, Christopher White Sr. Programmer 1-617-772-2403 Christopher.White@bbh.com From: sdoca sdoca <sdoca@shaw.ca> To: logback-user@qos.ch Date: 04/16/2012 01:39 PM Subject: [logback-user] How to load logback.xml from ear? Sent by: logback-user-bounces@qos.ch Hi, I have an ear file deployed to Glassfish (v.3.1.1) and cannot get the logback.xml to be loaded. I have bundled it in the ear in the META-INF directory. Where should it be located? Thanks!_______________________________________________ Logback-user mailing list Logback-user@qos.ch http://mailman.qos.ch/mailman/listinfo/logback-user *************************** IMPORTANT NOTE*****************************-- The opinions expressed in this message and/or any attachments are those of the author and not necessarily those of Brown Brothers Harriman & Co., its subsidiaries and affiliates ("BBH"). There is no guarantee that this message is either private or confidential, and it may have been altered by unauthorized sources without your or our knowledge. Nothing in the message is capable or intended to create any legally binding obligations on either party and it is not intended to provide legal advice. BBH accepts no responsibility for loss or damage from its use, including damage from virus. ********************************************************************************
participants (3)
-
Christopher.White@bbh.com
-
cinhtau
-
sdoca sdoca