-all

I can reassure all that the fault is *not* in the roll-strategy/algorithms.
It was not a concurrency bug in my own code either, but rather a combination
of rolling and the class
LOG4J_HOME/contribs/JimMoore/LoggingOutputStream.java. I'm probably not the
first one to fall into this trap.

I haven't investigated the error, but it probably has to do with LogLog
logging to stdout/stderr and falls into infinite recursion (or something
like that).

By pure accident I introduced file-rolling and the crucial class mentioned
above at the same time, withoug thinking about (or reading it in the
mailing-list-entries strategically located in the same folder as the class)
the implications for log4j itself that the standard streams are redirected.

Must admit that the whole case is quite embarrassing for yours truly, but I
guess this is one the painful lessons one sometimes need to learn on the
path to omniscience ;)

Thanks for everybodys concern and valuable feedback.

Regards,

--

Thomas





| -----Original Message-----
| From: Thomas Tuft Muller [mailto:[EMAIL PROTECTED]]
| Sent: 27 September 2001 15:22
| To: LOG4J Users Mailing List
| Subject: RE: Class A fault in rolling-file algorithm(s)
|
|
| Ceki,
|
| Please find my comments interspersed
|
| | On numerous occasions users have complained about deadlocks after
| | introducing log4j into their code. However, without exception the bug
| | was always in the application code not in log4j. Log4j may well
| | contain concurrency-related bugs but we need proof not vague
| | suspicions. Since you indicate that your code has a lot of concurrent
| | threads I suspect that the bug is in your code and not in log4j.
|
| You're probably right, but it may be worthwhile to attack the problem from
| both ends.
|
| | Which version of log4j is this?
|
| 1.1.3 (compiled with org.apache.log4j.CompositeRollingAppender, and an
| edited version of DOMConfigurator that reports errors with line-numbers
| included)
|
| | Which OS?
|
| Win 2000, 5.00.2195, Service Pack 2
|
| | Which JDK?
|
| java version "1.3.0"
| Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.0-C)
| Java HotSpot(TM) Server VM (build 2.0fcs-E, mixed mode)
|
| |
| | >I've now tried endless combinations of parameters to the different
| | >rollingfile appenders (CompositeRollingAppender,
| | DailyRollingFileAppender,
| | >RollingFileAppender) in log4j and they all make the application
| | hang after a
| | >rollover-attempt.
| |
| | How do you know if the hang occurs within a rollover attempt?
|
| Well, I've set up the logs to roll at 00:00:00 and all logging stops at
| 23:59:50 (ish). After this point the application is completely dead,
| probably due to a deadlock. The files that were supposed to be created are
| not.
|
| | I suggest that you perform your tests using a RollingFileAppender
| | using a small MaxFileSize, say 100 bytes.
|
| OK, thanks.
|
| | I am looking forward for your test case. Regards, Ceki
|
| Will report back here as soon as I have something.
|
| BTW: CompositeRollingAppender reports and error if MaxFileSize is not
| defined as a long (it does not tolerate xMB or yGB). Guess this has
| something to do with the fact that the setMaxFileSize is overloaded with
| long and string, and the reflection mechanism picks the wrong method(?).
|
| --
|
| Thomas
|
|
| |
| |
| | At 13:58 27.09.2001 +0100, Thomas Tuft Muller wrote:
| | >Stephen,
| | >
| | >Ceki pointed out that I was imprecise (and probably rude), and he was
| | >totally right. I went out of my way (my apologies to the log4j
| | development
| | >team). I didn't mean that other people should refrain from
| using log4j, I
| | >just pointed out that I personally will consider it in
| future/concurrent
| | >projects.
| | >
| | >This is by no means a proof that there is a flaw in Log4j, it
| | could turn out
| | >that it is in our application (even though it seems very
| unlikely at the
| | >time). This problem has my complete attention now, and I'm in
| | the process of
| | >writing a test-program that hopefully can isolate the situations
| | in which it
| | >occures and hopefully give a hint of where the fault is.
| | >
| | >Will send the results to Jon Skeet who most kindly promised to
| | look into it.
| | >
| | >Regards,
| | >
| | >--
| | >
| | >Thomas
| | >
| | >
| | >
| | >| -----Original Message-----
| | >| From: Stephen Levinson [mailto:[EMAIL PROTECTED]]
| | >| Sent: 27 September 2001 13:34
| | >| To: 'LOG4J Users Mailing List'
| | >| Subject: RE: Class A fault in rolling-file algorithm(s)
| | >|
| | >|
| | >| Dear Ceki...
| | >|
| | >|       I get the gist of the original message here... but what is your
| | >| reply?
| | >|
| | >|       We are gearing up to use log4j and this seems like an important
| | >| issue....
| | >|
| | >|       ... Please explain..
| | >|
| | >| Thanks alot, Stephen
| | >|
| | >|
| | >|
| | >| -----Original Message-----
| | >| From: Ceki Gülcü [mailto:[EMAIL PROTECTED]]
| | >| Sent: Thursday, September 27, 2001 7:35 AM
| | >| To: LOG4J Users Mailing List
| | >| Subject: Re: Class A fault in rolling-file algorithm(s)
| | >|
| | >|
| | >|
| | >| http://www.tuxedo.org/~esr/faqs/smart-questions.html
| | >|
| | >| At 10:57 27.09.2001 +0100, you wrote:
| | >| >Log4j users/developers
| | >| >
| | >| >I've now tried endless combinations of parameters to the different
| | >| >rollingfile appenders (CompositeRollingAppender,
| | >| DailyRollingFileAppender,
| | >| >RollingFileAppender) in log4j and they all make the application
| | >| hang after
| | >| a
| | >| >rollover-attempt.
| | >| >
| | >| >The application has a lot of threads and uses multiple appenders
| | >| for a lot
| | >| >of categories, some of them being async-appenders.
| | >| >
| | >| >This (unfortunately) shows that multithreading issues are NOT solved
| | >| >satisfactory in Log4j. Does anyone have any knowledge
| whether this is
| | >| >addressed by the development team, if there exists
| | fixes/updates etc? I
| | >| >could of course fix the problem myself, unfortunately my
| | >| schedule is pretty
| | >| >tight for the time being.
| | >|
| | >| >I'm seriously considering applying another logging package,
| and I will
| | >| >discourage use of log4j for other projects until this is solved.
| | >| Dont' get
| | >| >me wrong, I think log4j is an excellent logging package
| despite a few
| | >| design
| | >| >deficiencies, but no telco production system can tolerate to risk
| | >| >application hangs as likely as the system today proves.
| | >| >
| | >| >Regards,
| | >| >
| | >| >--
| | >| >
| | >| >Thomas
| | >| >
| | >| >
| | >| >
| | >| >
| | >| >
| | >| >
| | >| >
| | >| >
| | >| >
| | >| >
| | >| >
| | >| >
| | >|
| |
| >*************************************************************************
| | >| >Copyright ERA Technology Ltd. 2001. (www.era.co.uk). All rights
| | >| reserved.
| | >| >Confidential. No liability whatsoever is accepted for any
| | loss or damage
| | >| >suffered as a result of accessing this message or any attachments.
| | >| >
| | >|
| >---------------------------------------------------------------------
| | >| >To unsubscribe, e-mail: [EMAIL PROTECTED]
| | >| >For additional commands, e-mail: [EMAIL PROTECTED]
| | >|
| | >| --
| | >| Ceki Gülcü - http://qos.ch
| | >|
| | >| The world owes Israel a great debt for destroying Saddam's
| | >| French built nuclear reactor in 1981 and thus preventing
| | >| nuclear blackmail in the region and perhaps beyond.
| | >|                        -- Garry Kasparov (yes, the chess player)
| | >|
| | >|
| | >| ---------------------------------------------------------------------
| | >| To unsubscribe, e-mail: [EMAIL PROTECTED]
| | >| For additional commands, e-mail: [EMAIL PROTECTED]
| | >|
| | >| ---------------------------------------------------------------------
| | >| To unsubscribe, e-mail: [EMAIL PROTECTED]
| | >| For additional commands, e-mail: [EMAIL PROTECTED]
| | >|
| | >|
| | >
| | >
| | >
| |
| >*************************************************************************
| | >Copyright ERA Technology Ltd. 2001. (www.era.co.uk). All rights
| | reserved.
| | >Confidential. No liability whatsoever is accepted for any loss
| or damage
| | >suffered as a result of accessing this message or any attachments.
| | >
| | >---------------------------------------------------------------------
| | >To unsubscribe, e-mail: [EMAIL PROTECTED]
| | >For additional commands, e-mail: [EMAIL PROTECTED]
| |
| | --
| | Ceki Gülcü - http://qos.ch
| |
| | The world owes Israel a great debt for destroying Saddam's
| | French built nuclear reactor in 1981 and thus preventing
| | nuclear blackmail in the region and perhaps beyond.
| |                        -- Garry Kasparov (yes, the chess player)
| |
| |
| | ---------------------------------------------------------------------
| | To unsubscribe, e-mail: [EMAIL PROTECTED]
| | For additional commands, e-mail: [EMAIL PROTECTED]
| |
| |
|
|
|
| *************************************************************************
| Copyright ERA Technology Ltd. 2001. (www.era.co.uk). All rights reserved.
| Confidential. No liability whatsoever is accepted for any loss or damage
| suffered as a result of accessing this message or any attachments.
|
| ---------------------------------------------------------------------
| To unsubscribe, e-mail: [EMAIL PROTECTED]
| For additional commands, e-mail: [EMAIL PROTECTED]
|
|



*************************************************************************
Copyright ERA Technology Ltd. 2001. (www.era.co.uk). All rights reserved. 
Confidential. No liability whatsoever is accepted for any loss or damage 
suffered as a result of accessing this message or any attachments.

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

Reply via email to