All,
 
I was recently working on a project which was very time sensitive.
Milliseconds were prescious, and we had great interest in using LOG4CXX,
only in debugging problems (where time wasn't nearly as critical).
 
On the web site, I saw that getLogger("asdf") will return the same
object as a subsequent call to getLogger("asdf").  When we created
multiple objects of the same type, each of which had a logger instance
with the same name, we profiled the code, and found that eacy
getLogger() call was taking quite a lot of time.  Unfortunately the
numbers are lost, but it was something like 100 us or ms.  These numbers
are a world apart, but when it came to creating ~1000 of my own objects,
the amount of time spent creating those loggers became unacceptable.
 
We ultimately found that by creating a caching mechanism using a
"loggerName" -> "loggerObject" map, made the subsequent calls much more
manageable.  
 
I was just wondering if anyone else has seen this sort of behavior.
 
--dw

Reply via email to