tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jean-frederic Clere <jfcl...@telefonica.net>
Subject Re: mod_jk logging buffer
Date Sun, 14 Aug 2005 18:29:59 GMT
Mladen Turk wrote:

> Jean-frederic Clere wrote:
>
>> Radek Wierzbicki wrote:
>>
>>> Hello,
>>>
>>
>> better :
>> if (l->level < JK_LOG_INFO_LEVEL || level==JK_LOG_EMERG || 
>> level==JK_LOG_ERROR)
>> No?
>>
>
> Flush should not be executed for INFO level. It slows the things
> down by the factor of 2. I agree for ERROR and EMERG.
> DEBUG and TRACE uses fflush so the order of messages can be traced,
> but that is also dubious because the messages could come from
> different threads, so the best would be to use the fflush only
> with ERROR and EMERGE levels.

So it is OK to commit the following:
++++++
RCS file: /home/cvs/jakarta-tomcat-connectors/jk/native/common/jk_util.c,v
retrieving revision 1.71
diff -u -r1.71 jk_util.c
--- common/jk_util.c    1 Jul 2005 15:41:08 -0000       1.71
+++ common/jk_util.c    14 Aug 2005 18:28:29 -0000
@@ -186,7 +186,7 @@
             fwrite(what, 1, sz, p->logfile);
             fputc('\n', p->logfile);
             /* [V] Flush the dam' thing! */
-            if (l->level < JK_LOG_INFO_LEVEL)
+            if (l->level < JK_LOG_INFO_LEVEL || level==JK_LOG_EMERG || 
level==JK_LOG_ERROR)
                 fflush(p->logfile);
         }

++++++
isn't it?

>
> Regards,
> Mladen.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org


Mime
View raw message