Re: Error Handling Strategy

2005-06-08 Thread Leandro_Dorileo/ABACO
In my new application design I am employeeing this strategy and using custom ExceptionHandler classes to catch, log, and redirect the user to the appropriate pages. In my Exception classes, instead of a non-localized string as the exception message, I use a message key which I can then retrieve

Error Handling Strategy

2005-06-06 Thread Matthew Hughes
I really do not like the way my current application handles errors as every error requires three or four lines and it is very redundant. I have been reading a lot about Exception(s) and how developers are slowly seeing the benefits of extending their Exception(s) from RuntimeException freeing

Re: Error Handling Strategy

2005-06-06 Thread Rick Reumann
Matthew Hughes wrote the following on 6/6/2005 12:21 PM: Can anyone tell me why this isn't a good idea? I've found it easiest to not have any try/catch logic in my Actions, and I just define the global exceptions I want to catch in my struts-config which forwards to an action that logs my

Re: Error Handling Strategy

2005-06-06 Thread Frank W. Zammetti
I've gotten into the habit of using the Struts global exception handling mechanism... Anything that can be handled in my code I catch and handle (i.e., retrying a connection to a back-end system perhaps), anything else I let bubble up and handle it in the global handler. This to me is pretty much

Re: Error Handling Strategy

2005-06-06 Thread Xinsheng \[mike\] Huang
Rule 1: let the global exception handler handle the unwanted-exceptions,usually they are system exceptions. Rule 2: for business exceptions that your action catchs and put an action error/message in request so that the jsp displays a message to user to recovery. A business exception is required

Re: Error Handling Strategy

2005-06-06 Thread Martin Gainty
Mailing List user@struts.apache.org Sent: Monday, June 06, 2005 3:59 PM Subject: Re: Error Handling Strategy Rule 1: let the global exception handler handle the unwanted-exceptions,usually they are system exceptions. Rule 2: for business exceptions that your action catchs and put an action error

Re: Error Handling Strategy

2005-06-06 Thread Xinsheng \[mike\] Huang
: Error Handling Strategy Rule 1: let the global exception handler handle the unwanted-exceptions,usually they are system exceptions. Rule 2: for business exceptions that your action catchs and put an action error/message in request so that the jsp displays a message to user to recovery