users@glassfish.java.net

JEE5 exception handling best practices

From: <glassfish_at_javadesktop.org>
Date: Tue, 02 Dec 2008 08:44:11 PST

Hello,

Is there some documentation about exception handling best practices?
For example how should I handle uncaught exceptions in case of EJBs (eg. logging them).

Some more concrete info: I use an slf4j+logback based logger in my application. When an EJB throws an exception (like "throw new RuntimeException();"), this exception is not logged to the logback log file but to the server log as a javax.ejb.EJBException.
What I want is to log some useful info to the logback-based "application log" as well.

Do you have some suggestions?

Thanks:
Norbi
[Message sent by forum member 'snorbicet' (snorbicet)]

http://forums.java.net/jive/thread.jspa?messageID=319593