logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Steven Keens" <ke...@pcigeomatics.com>
Subject Log stack trace or simply message option?
Date Mon, 27 Apr 2009 18:54:26 GMT

In some places in my code I use the Logger.error(String msg, Throwable
t) function to emit log events.  When running in "release" mode I'd like
to just simply show the log message.  When running in "debug" mode I'd
like to show the full stack trace.

Is there a way to disable logging the stack trace based upon a
configuration option? Would I have to write my own code?

I did a relatively quick scan through the source and could not find a
way to do it.

Steven Keens
"Duct tape is like the force. It has a light side, a dark side, and it
holds the universe together."  - Carl Zwanzig
PCI Geomatics
OGC Technical Representative
Phone: 819-770-0022 x204
Fax: 819-770-0098
Email: skeens@pcigeomatics.com
Website: www.pcigeomatics.com

To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org

View raw message