In my opinion Log4J is a much more mature logging implementation proven in countless applications, both J2SE and J2EE applications. As with anything created by committe I think the J2SE logging lacks a lot of the features that appear in an API from extensive usage in heterogenous environments. I personally use Commons Logging usually fronting Log4J. For J2SE apps I sometimes use the J2SE logging but never for J2EE applications.
Co-Author of <a href="http://www.amazon.com/exec/obidos/ASIN/1590591259/ref=jranch-20" target="_blank" rel="nofollow">Enterprise Java Development on a Budget</a>
I found the 1.4 implementation to be decent but limited when compared to log4j. Plus, although it's been a while, I thought it was hard to find decent documentation but that may have changed by now. My organization has quite a few apps that use commons logging and/or log4j. Both, in my opinion are better that the current Sun implementation.
No more rhymes! I mean it!<br /> <br />Does anybody want a peanut?
I would be perfectly satisfied with JDK Logging API if only they had included a facility similar to Log4J's DailyRollingFileAppender. I can't believe they didn't include a date-based rolling file appender even though they did include a file size-based one. Sigh.
Thanks for all your reply ! How do u guys learn log4j before any book is available ? Just by Apache on line documents ? I tried Apache on line documents for Struts, Commons(Pool, DBCP) before. I have to say I am not smart enough to learn well by those free document. This new book is an overall introduction, not for learning a specific technologies. I am wondering if I can read this book for a general idea and learn each specific item by on-line document ?