Hi,
Thanks for the reply.
My thoughts are along these lines:
> Yes, the call should be on Logger and possibly also on LoggerRepository.
> Async-like appenders should not block until queue is empty but mark from
> where to flush the queue
and support read/write on different sections of the queue (so only the messages
at the time of call will be flushed, while other messages
can be written to a different section of the queue in between)
> Concerning the general issue of log-while-flush, I guess it is dependent upon
> the multi-threading support of the actual output stream
which can vary between different appenders.
Lastly, potentially I can create a patch, but I am on a long leave starting
tomorrow, until around February...
So I am not sure it would be a good idea to wait for me, but I guess it depends
on how much demand there is for this feature.
Thanks again,
Barak
[EMAIL PROTECTED]
g To:
[email protected]
cc:
21/12/2004 18:07 Subject: Re: Request:
flushAll() method on loggers for writer appenders
Please respond to
log4cxx-dev
I did see your earlier message and thought that I had replied to it,
but can't seem to find a message in the archives.
I'd like to get Ceki's opinion on this. I can see where it would be
useful to you, but I'm sure that there are probably issues that need to
be considered.
The appropriate location for the call, putting it on the appender isn't
very handy. Maybe Logger.flush() and LoggerRepository.flushAll()?
What guarantees do you want after the return from flush/flushAll()?
Should a network or async appender block until its queue is empty? Or
do you just want to just hint that it would be a good time to flush
buffers?
What happens to if a log request is made during the execution of
flush(), should it block until completion and be done after the flush
is complete?
If we can work through the issues, would you be willing to submit
patches to log4j and log4cxx?
If you'd like to take the question to the log4j-dev mailing list (which
I subscribe to), you might get more lively discussion.
--
This e-mail may contain confidential and/or privileged information. If you are
not the intended recipient (or have received this e-mail in error) please
notify the sender immediately and destroy this e-mail. Any unauthorized
copying, disclosure or distribution of the material in this e-mail is strictly
forbidden.