[slf4j-dev] [Bug 70] " logging a stack trace along with a parameterized string" solution proposal
bugzilla-daemon at pixie.qos.ch
bugzilla-daemon at pixie.qos.ch
Tue Jan 29 20:48:15 CET 2008
http://bugzilla.slf4j.org/show_bug.cgi?id=70
listid at qos.ch changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |REMIND
------- Comment #4 from listid at qos.ch 2008-01-29 20:48 -------
I am inclined to decline this patch for the sake of simplicity.
Considering that message formatting is just a trick to improve performance,
there is no real performance loss in writing:
} catch(Exception e) {
logger.error("Problem saying hello to " + name, e);
}
instead of
} catch(Exception e) {
logger.error("Problem saying hello to {}", name, e);
}
However, the latter form causes the exception to be lost, which is pretty bad.
I think this can be dealt with by style correctors such as Checkstyle or PMD.
It should also be possible to write our own IDE plugin.
In short, I am wary of introducing a new behaviour to the org.slf4j.Logger
interface even if the method signatures remain the same.
--
Configure bugmail: http://bugzilla.slf4j.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
More information about the slf4j-dev
mailing list