[logback-dev] [JIRA] Created: (LBCLASSIC-174) LoggingContextSelect JNDI No context creating threads in a EJB
Miguel Goyena (JIRA)
noreply-jira at qos.ch
Mon Dec 14 20:44:33 CET 2009
LoggingContextSelect JNDI No context creating threads in a EJB
--------------------------------------------------------------
Key: LBCLASSIC-174
URL: http://jira.qos.ch/browse/LBCLASSIC-174
Project: logback-classic
Issue Type: Bug
Environment: Application (EJB jar, WAR) deployed in JBOSS 5.0.1
Reporter: Miguel Goyena
Assignee: Logback dev list
I'm using LoggingContextSelect JNDI.
My application es an ear deployed in JBOSS, with three WAR and a EJB
session jar.
One of the servlet in a WAR uses the Sesssion EJB. In the EJB Session
Method I create a Thread, and start it
MandarMensajes threadException = new MandarMensajes(tipo,cuantos,cadaCuanto);
threadException.start();
In this thread the run method uses logback for logging.
Logger logger = LoggerFactory.getLogger(this);
logger.logDebug("Hello");
But the logger I get have a default context!!!!!!, not the context defined
in the JNDI.
Only happends this when a use the thread in the Session EJB.
If I use the MandarMensajes thread in the servlet everything is correct.
If I get a logger anywhere else in the EJB Session everything is correct.
If I use the run() method of ManderMensajes in the EJB Session everything is correct.
Even if I get the MDC objet when thread is executing, all the values I put in servletare there; b
ut the context is default, so it never uses my logback-Application.xml config file!!!!.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.qos.ch/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the logback-dev
mailing list