axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Afkham Azeez (JIRA)" <>
Subject [jira] [Updated] (AXIS2-5020) ClassCastExceptions between two axis2 client jars with different package
Date Tue, 17 May 2011 16:56:47 GMT


Afkham Azeez updated AXIS2-5020:

    Priority: Major  (was: Blocker)

This seems to be a configuration issue on the client. Anyway, if at all such an issue exists,
the workaround is to have them in two different WAR files or EARs. This is certainly not a

> ClassCastExceptions between two axis2 client jars with different package
> ------------------------------------------------------------------------
>                 Key: AXIS2-5020
>                 URL:
>             Project: Axis2
>          Issue Type: Bug
>          Components: client-api
>    Affects Versions: 1.5
>         Environment: Windows XP, Java 1.6. 
>            Reporter: Sunny Wu
> In one EAR file, we have two client jars generated against the same wsdl. Both are using
the org.apache.axis2.wsdl.WSDL2Java -uri <wsdl> -p <filepath> -d xmlbeans -ns2p
> ClientA proxy classes have package name as a. 
> ClientB proxy classes have package name as b.
> in,  we use the clientA like: 
> import a.ResponseDocumet;
> import a.Stub;
> responseDocument responseDoc =  ResponseDocument.Factory.newInstance();
> ....
> responseDoc = stub.sameMethod(...);
> ------------------------------------------------------------------------------------------------------------------------------------------------------------
> in, we use the ClientB like:
> import b.ResponseDocumet;
> import b.Stub;
> ResponseDocument responseDoc =  ResponseDocument.Factory.newInstance();
> ....
> responseDoc = stub.sameMethod(...);
> ----------------------------------------------------------------------------------------------------------------------------------------------------------------
> It doesn't have any problem in compile. And is also working correctly at runtime.
But got this exception at runtime:
> org.apache.axis2.AxisFault: a.impl.ResponseDocumentImpl with cause as java.lang.ClassCastException:
> It should be using b package, but don't know why it referred to a in the stub implementation.
> It will be highly appreciated if you can help.

This message is automatically generated by JIRA.
For more information on JIRA, see:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message