logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ceki Gülcü <...@qos.ch>
Subject RE: log4j and J2EE problem
Date Wed, 08 Aug 2001 20:12:09 GMT
At 15:47 08.08.2001 -0400, Kenji Konaka wrote:
> > , is that Weblogic uses two classloaders per application.  One for EJBs
> > and one for the webapp with the webapp's class loader being a child of
> > the EJB's class loader.
> > 
> > So, how are people initialing log4j so that there is a single singleton
> > per application in Weblogic? 
>if EJBclassloader was the parent of the WEBAPPclassloader,
>then putting log4j simply in EJBclassloader's loadpath, may
>simply results in both EJBside & WEBapp side using the same
>singleton (per application), as _usually_ each classloaders
>consult its parent before trying its own classpath...
>but then at least if its within webapp's side, I think it's
>just free to reset one's context classloader, so maybe the
>webapp can temporarily reset its classloader to that of the
>ejbapp while it is constructing log4j related stuff, and
>then rever to its original when done.
>then I'm not really sure if it was allowed to reset one's
>contextclassloader within the code for EJB beans. (wrong?)

Nope, it really is not allowed. Even then, it probably would not help and would surely cause
a lot of headache. I'd really would not go down this road but that's just mho. Ceki

Ceki Gülcü - http://qos.ch

To unsubscribe, e-mail: log4j-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: log4j-user-help@jakarta.apache.org

View raw message