commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 38174] - [logging][PATCH] Improvements to wrapper classes
Date Sun, 08 Jan 2006 16:37:37 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=38174>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=38174





------- Additional Comments From boris.unckel.mlg@gmx.net  2006-01-08 17:37 -------
(In reply to comment #4)
> At least for log4j, this is wrong, since the conversion of Objects to Strings 
> is controlled by the log4j configuration.  With this patch, you've preempted 
> that functionallity.

You are right. log4j suffers currently from the same problem (no exception safe
message rendering). It is a design decision to have _one_ behaviour for all
classes, or  one behaviour for underlying logging supporting object as message
and another for underlying APIs which require String.

I would suggest to apply the patch now (since log4j has no exception safe
rendering) and change it, if it has the capability to deal with exceptions in
toString.

Or in other words:
What causes the user more pain: Missing individual formatting or missing a good
exception handling strategy?
The org.apache.log4j.or.DefaultRenderer does nothing but o.toString()

The patch has one advantage: You would have to change at one single place per
Log4j1xLogger (x 2,3)...

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

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


Mime
View raw message