On Apr 12, 2008, at 12:17 PM, Ron Grabowski wrote:

This is a faster pattern converter for the "yyyy-MM-dd hh:mm:ss tt" pattern. I use this primarily with my NHibernate logger in DEBUG mode because I want to see what NHibernate is doing but I don't necessarily care about timings down to the millisecond when its writing out its generated sql and building objects. When I use this pattern converter my app doesn't feel slow when NHibenrate DEBUG logging is enabled:


You might also look at the CachedDateFormat from log4j 1.3, backported to the extras companion:

https://svn.apache.org/repos/asf/logging/log4j/companions/extras/trunk/src/main/java/org/apache/log4j/pattern/CachedDateFormat.java

Basically, it provides caching of an arbitrary DateFormat.

Reply via email to