Hi,

 

Please suggest the exception framework in a scenario in a following scenario.

 

Struts Action class  à Business Delegate --> EJB à OR Mapping (Top link) à Domain classes

 

Please validate the below lines.

 

There will be three layers at which we need to handle the exception.

 

At EJB layer, at business delegate and at struts layer.

 

  1. EJB layer (session bean) methods will throw the (Application) business exceptions along with RemoteException. In the catch block it will throw the EJBException (in case of checked system exceptions like NamingException).
  2. At business delegate layer, we will throw the application exceptions in the catch block rather than EJBException to decouple the web layer and EJB layer.
  3. At struts layer, in the Action class’s execute(), we will catch all these business exceptions.

 

Please provide your valuable inputs.

 

Thanks in advance.

 

 

 

 

 

 

 

 

 

 

 

 

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to