[logback-user] configuration through JNDI
bjorn rohde jensen
bjensen at fastmail.fm
Mon Jun 18 16:44:38 CEST 2012
I recently switched to logback, and im trying to use JNDI to configure
logback for webapps running in tomcat 6.
What i want to do is configure logging for each webapp using a different
configuration file for each tomcat context. The logback configurations
must be external to the wars and to the tomcat installation. Furthermore
i cant rely on environment variables or -D options to the tomcat.
The only solution, i have come up with so far is to pack a skeleton
logback configuration file in the war, which uses logbacks JNDI and
include mechanisms to locate and include a file containing the real
configuration like so:
<configuration scan="true" scanPeriod="5 minutes">
While this does work, i would prefer being able to lookup the full
Is there a way to do this, or could one be added?
Bjorn R. Jensen
More information about the Logback-user