You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-user@logging.apache.org by Jin-Shin Chou <ja...@alcatel-lucent.com> on 2008/04/14 05:05:05 UTC
-- log4j exceptions
Hi log4j users:
We encountered log4j exceptions while running java application,
don't know if you encountered the same problem before.
Attached is the extraction of the trace file starting from line #4177.
Thanks in advance.
jason
--
Background info:
The application is run on
- HP PA-RISC machine,
- java 1.5,
- log4j-1.2.13,
tried on log4j-1.2.14 and got the same errors,
- the error seems to happen at random while writing log using log4j.
- there are 5 log4j related exceptions in this trace file,
ERR#1: (near line #4183)
4183 at
org.apache.log4j.helpers.PatternParser$LiteralPatternConverter.format(PatternParser.java:412)
ERR#2: (near line #5500)
5500 at
org.apache.log4j.helpers.PatternConverter.format(PatternConverter.java:79)
ERR#3: (near line #9393)
9393 at org.apache.log4j.PatternLayout.format(PatternLayout.java:486)
ERR#4: (near line #9428)
9428 at org.apache.log4j.PatternLayout.format(PatternLayout.java:486)
ERR#5: (near line #9474)
9474 at org.apache.log4j.PatternLayout.format(PatternLayout.java:486)
-----
Re: -- log4j exceptions
Posted by Paul Smith <ps...@aconex.com>.
On 14/04/2008, at 1:05 PM, Jin-Shin Chou wrote:
> Hi log4j users:
>
> We encountered log4j exceptions while running java application,
> don't know if you encountered the same problem before.
> Attached is the extraction of the trace file starting from line #4177.
> Thanks in advance.
>
What is the Pattern layout format string in use in this case?
cheers,
Paul
---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org
Re: -- log4j exceptions
Posted by Curt Arnold <ca...@apache.org>.
On Apr 13, 2008, at 10:05 PM, Jin-Shin Chou wrote:
> Hi log4j users:
>
> We encountered log4j exceptions while running java application,
> don't know if you encountered the same problem before.
> Attached is the extraction of the trace file starting from line #4177.
> Thanks in advance.
> jason
> --
> Background info:
> The application is run on
> - HP PA-RISC machine,
> - java 1.5,
> - log4j-1.2.13,
> tried on log4j-1.2.14 and got the same errors,
> - the error seems to happen at random while writing log using log4j.
>
> - there are 5 log4j related exceptions in this trace file,
> ERR#1: (near line #4183)
> 4183 at
> org.apache.log4j.helpers.PatternParser
> $LiteralPatternConverter.format(PatternParser.java:412)
>
> ERR#2: (near line #5500)
> 5500 at
> org
> .apache.log4j.helpers.PatternConverter.format(PatternConverter.java:
> 79)
>
> ERR#3: (near line #9393)
> 9393 at org.apache.log4j.PatternLayout.format(PatternLayout.java:486)
>
> ERR#4: (near line #9428)
> 9428 at org.apache.log4j.PatternLayout.format(PatternLayout.java:486)
>
> ERR#5: (near line #9474)
> 9474 at org.apache.log4j.PatternLayout.format(PatternLayout.java:486)
The line numbers reported do not agree with the corresponding code
from log4j 1.2.13, however they do match up with log4j 1.2.8. Perhaps
you have a log4j 1.2.8 or so installed and it using that instead of
the log4j that you think that you are using. Once you figure that
out, could you try again with log4j 1.2.15 (the current release) and
see if the problem persists.
However, looking at the StringBuffer.capacity() stack trace it looks
like it may be a JVM bug or maybe a class loader bug. If you are
throwing a NPE from within StringBuffer.capacity()'s implementation,.
either "this" is null which doesn't seem achievable by normal language
means in PatternLayout or there is some corruption in the internal
state of StringBuffer. The Tomcat class loader has caused a decent
amount of problems for us since it can, under certain conditions,
result in instances that violate what should be class invariants.
If it still persists, then try seeing if the problem still persists
with the latest JDK for the platform.
---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org