tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From <>
Subject Re: VOTE: Timestamps in log
Date Wed, 05 Jul 2000 17:53:40 GMT
> My rule of thumb in programming is "don't pre-optimize".  Most people
> using Tomcat will not be running high-load web sites (since most
> people in the world don't run high-load web sites) so it's better to
> optimize for clarity over performance.  

I think this is far from a "pre-optimize" case - we are talking about a
default option in the final product ( maybe post-optimize). 

Time-stamping anything but the access log is a waste, and formating the
date is also a waste.  

> Also, given that the log writer is running in a backround thread
> anyway (nice design, whoever wrote that, btw), it will never impact
> the latency of a request in any case.

I spent last months tuning up tomcat, and believe me - GC has a huge
impact in latency.

Most of the performance improvements between tocmat 3.1 and 3.2 comes from
reducing the GC and reusing the objects. Date formating is a big GC
generator, and it's almost imposible to reuse the date formating objects
with the current API ( or I coulnd't find a way ). 

> (Anyone replying may say +1 for "2000-07-04 13:45:11" and -1 for
> "963636252"; if nobody but Costin objects, I'll keep it how it is by
> default.)

AFAIK a -1 with valid reasons is a veto. Anyway, if you feel it's so
important to have formated dates by default - I'm fine, you can go ahead.

I would be happy to vote +1 if you find a way to format the date that
allows object reuse ! 
( and again - it wouldn't be pre-optimization )


View raw message