logging-log4cxx-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christophe de VIENNE <cdevie...@alphacent.com>
Subject Re: Buffering Questions
Date Wed, 15 Sep 2004 09:22:39 GMT

Barak Simon wrote:

>The following questions are about FileAppender and AsyncAppender buffering:
>1. I found an example of how to configure the FileAppender to buffer the logging events:
>    <param name="ImmediateFlush" value="false"/>
>    <param name="BufferedIO" value="true"/>
>    (a) What's the difference between buffering and not-flushing (are there 4 distinct
combinations I can configure?)
>    (b) Is there a way to configure the buffer size? (from script that is)

 From what I see in the source :

BufferedIO = true implies ImmediateFlush = false

ImmediateFlush is handled by WriterAppender, which will do a ostream::flush after each output.

BufferedIO is specific to FileAppender. The buffer size can be set via the "buffersize" property.
However is seems that those properties (bufferedIO and buffersize) will be silently ignored,
since the relevant code is commented.

>2. I could not find an example in the log4cxx side (there might be one on the java side)
of how to configure the buffer size
>    for the async appender.
Do you mean by configuration script ?
In the source the function is setBufferSize. I guess a buffersize 
property is usable in the script. Note that ASyncAppender can only be 
script configured using an xml file.

>    (And in general, is there a place where one can find the complete dtd in use?)
I don't know.



Christophe de Vienne
Alpha Centauri
tel: 01 47 82 93 78

View raw message