geronimo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "gianny DAMOUR" <gianny_dam...@hotmail.com>
Subject Re: [Exceptions] [i18n] Hardcoded message strings
Date Thu, 28 Aug 2003 23:35:33 GMT
Hello,

Alex wrote:
>For logging exceptions, I strongly think that the logging mechanism should 
>do:
>
>log(e.getClass() + ":" + e.getLocalizedMessage());
>   or
>log(e.toString())
>
>rather than
>
>log(e.getMessage())

I see a problem in both cases: the stack trace - the exact location where 
the exception has been thrown - is lost.

Personally, I always use:
log.error("additional information", yourException);

Cheers,
Gianny

_________________________________________________________________
MSN Messenger 6 http://g.msn.fr/FR1001/866  : dialoguez en son et en image 
avec vos amis.


Mime
View raw message