You are viewing a plain text version of this content. The canonical link for it is here.
Posted to slide-dev@jakarta.apache.org by Dirk Verbeeck <di...@pandora.be> on 2001/07/25 22:52:41 UTC

Better way of printing exceptions...

Hi

I have just changed the loggers to print the stacktrace if the msg given
is a Throwable.

>From now on, to print a stacktrace just use:

Domain.error(e);
or
getLogger().log(e, Logger.ERROR);

this way the stacktrace ends up in the logfile if you are using log4j.

Dirk