beehive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Daryl Olander" <>
Subject Fwd: commons-logging and static log members
Date Wed, 08 Mar 2006 17:31:35 GMT
FYI...From the Struts List...I know that NetUI uses this (anti-)pattern all
over it.  I'm pretty sure we are not deploying in shared classloaders, but
I'm not sure of all of the scenario's we expect to be deployed in.  I don't
believe this pattern is used in Controls at all.

---------- Forwarded message ----------
From: Simon Kitching <>
Date: Mar 7, 2006 7:50 PM
Subject: commons-logging and static log members

Hi All,

Recently there was a discussion on the MyFaces list regarding the use of
the following pattern with commons logging classes:
  private static Log log = LogFactory.getLog(Foo.class)

It was pointed out that the use of static here is a really bad idea for
any code that may be deployed via a shared classloader in a container.
Craig McClanahan indicated that this (anti-)pattern was in use in struts
code and that the issue should be pointed out here.

I haven't personally checked whether this usage *is* present in the
current struts codebase. Neither do I know whether struts jarfiles are
expected to be deployed in shared classpaths (it's definitely true for

More information on this issue can be found here:


Simon (commons-logging committer)

To unsubscribe, e-mail:
For additional commands, e-mail:

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message