Log4j computes location information by throwing an exception which is caught immediately and parsing the stack trace of the exception. Apparently, creating an exception on AIX is slower than on other platforms.


As throwing exception is not something one does very frequently, the speed at which exceptions can be thrown is not a problem usually. With the %M, %F, %C conversion characters log4j abuses that hypothesis.


At 02:52 PM 2/2/2004 +0000, Robbie Baldock wrote:
Pete Stokes wrote:

> We have massive performance problems on an app running on iSeries
> WebSphere 4.0.7 (it uses log4j). The app works perfectly on all other
> platforms / servers.
>
> Someone in the Tomcat users list mentioned that there was talk regarding
> a certain log4j attribute when used on the IBM JVM caused big
> performance problems.
>
> Does this ring a bell with any1 ?

Yes! In a word, don't use %C...!

More info here:

http://logging.apache.org/log4j/docs/api/org/apache/log4j/performance/Loggin
g.html

(in particular point 6).

I'm still hoping someone on the log4j team will be able to explain what the
problem is with log4j and AIX and if/when the issue is ever likely to be
resolved.

I have to say I find this problem quite ironic given that log4j started its
life as an IBM project...!!!


Robbie

-- Ceki G�lc�

For log4j documentation consider "The complete log4j manual"
ISBN: 2970036908 http://www.qos.ch/shop/products/clm_t.jsp




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to