https://issues.apache.org/bugzilla/show_bug.cgi?id=43867





--- Comment #35 from Aaron Digulla <[EMAIL PROTECTED]>  2008-07-09 00:13:43 PST 
---
(In reply to comment #34)

Please go through your own argument once more as someone who isn't stuck in it.
Try to find answers to these questions:

1. Why is a logger method being called in clearReferences()? Tomcat doesn't use
log4j, it uses java.util.Logging. So your webapp must somehow put code
somewhere which Tomcat executes during shutdown.

2. When log4j notices that its static variables have been cleared, what should
it print? The current stack trace would give no hint who cleared the variable
because this probably has happened a long time ago, probably by some other
thread. If it would print the stack trace the moment the variable is being
cleared, you would see that you're inside the Tomcat cleanup code because your
webapp is being undeployed. No surprise here and no information either. IIRC,
there is another reason why the stack trace doesn't help but I can't recall it.
You'll see it immediately when you try to debug this.

So you must find out: a) why is a logger called and b) who registered this
piece of code which is executed after your webapp is supposed to be long gone?

Again: In your case, there is no need for another thread. All this can happen
in the main thread and there are more ways to log during app exit than the
shutdown hooks. Just put a breakpoint in the place where log4j prints the error
message and see who is trying to log.

But it's a bug in your webapp (and I'm counting all the JARs you include as
"your" here :) and not in log4j.


-- 
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

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

Reply via email to