tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject [Bug 60381] Inconsistent toString() in ValveBase and RealmBase
Date Mon, 21 Nov 2016 13:17:20 GMT
https://bz.apache.org/bugzilla/show_bug.cgi?id=60381

--- Comment #2 from Mark Thomas <markt@apache.org> ---
The toString() implementations have been pretty much unchanged since the
lifecycle refactoring in 7.0.x. While users shouldn't not be expecting these to
be in any particular format, the chances are that there that some users are
expecting the current format. Therefore, we can look at this for trunk but I
don't think it should be back-ported.

My current thinking for a standardised format is:
SimpleClassName[container.toString()] / SimpleClassName[Container is null]

This could/should apply to any component that is usually associated with a
single container (Valve, Realm, Manager, etc.)

If we make more use of the Contained interface, it should be possible to do
this as a single utility method e.g.:
o.a.c.util.DebugUtil.containedToString(Contained)

Although, that won't work with Manager, Loader etc. that are Context specific.

Maybe
o.a.c.util.DebugUtil.containedToString(Object, Container)
as well for those objects that don't/can't implement Contained.

Which means we might not need to expand the use of Contained anyway. I need to
spend some time thinking about how much sense that does or doesn't make.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message