You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by "Davanum Srinivas (JIRA)" <ax...@ws.apache.org> on 2004/10/25 16:53:44 UTC

[jira] Resolved: (AXIS-1577) EJBProvider doesn't handle java.rmi.ServerException

     [ http://issues.apache.org/jira/browse/AXIS-1577?page=history ]
     
Davanum Srinivas resolved AXIS-1577:
------------------------------------

    Resolution: Fixed

Applied Patch.

thanks,
dims

> EJBProvider doesn't handle java.rmi.ServerException
> ---------------------------------------------------
>
>          Key: AXIS-1577
>          URL: http://issues.apache.org/jira/browse/AXIS-1577
>      Project: Axis
>         Type: Bug
>   Components: Basic Architecture
>     Versions: current (nightly)
>  Environment: All OS, J2EE 1.3 (JBoss 3.2.3) using JDK 1.4.2_05
>     Reporter: David Green

>
> java.rmi.ServerException is thrown when a RuntimeException is thrown.  Since the original exception is wrapped in a ServerException, the SOAP fault is not created properly.
> The EJBProvider should override invokeMethod as follows:
> protected Object invokeMethod(MessageContext msgContext, Method method, Object obj, Object[] argValues) throws Exception {
>         try {
>             return super.invokeMethod(msgContext, method, obj, argValues);
>         } catch (ServerException serverException) {
>             throw (RuntimeException) serverException.getCause();
>         }
>     }
> This will ensure that the original exception is handled properly according to the type mappings.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira