[jboss-user] [JBossWS] - ClassCastException @ BaseDeserializerFactory.getSpecialized

vasquezr do-not-reply at jboss.com
Tue Oct 9 14:24:08 EDT 2007


Using Jboss 4.0.2.
Have a web service client(dyamic proxy method) that uses a complex type as a return parameter which consists of two java Object (WSDL anyType ).
The web service and client both worked until there was an attempt to add security to the application which housed the ejb endpoint.

The following code was added to the dynamic proxy client in order to get it to send a username and password.

Stub stub = (Stub)myService;
stub._setProperty(Stub.USERNAME_PROPERTY,username);
stub._setProperty(Stub.PASSWORD_PROPERTY,password);
myResult = myService.runServiceMethod(x,y,z);


This seems to get past the authentication issue but is now throwing the following exception
Exception:java.rmi.RemoteException: null; nested exception is: 
	java.lang.ClassCastException,Stack:java.rmi.RemoteException: null; nested exception is: 
	java.lang.ClassCastException
	at org.jboss.webservice.client.PortProxy.invoke(PortProxy.java:176)
	at $Proxy1.runJob(Unknown Source)
...
...
Caused by: java.lang.ClassCastException
	at org.jboss.axis.encoding.ser.BaseDeserializerFactory.getSpecialized(BaseDeserializerFactory.java:200)
	at org.jboss.axis.encoding.ser.BaseDeserializerFactory.getDeserializerAs(BaseDeserializerFactory.java:118)
	at org.jboss.axis.encoding.DeserializationContextImpl.getDeserializer(DeserializationContextImpl.java:574)
	at org.jboss.axis.message.RPCHandler.onStartChild(RPCHandler.java:309)
	at org.jboss.axis.encoding.DeserializationContextImpl.startElement(DeserializationContextImpl.java:1168)
	at org.jboss.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:244)
	at org.jboss.axis.message.SOAPElementAxisImpl.publishToHandler(SOAPElementAxisImpl.java:1386)
	at org.jboss.axis.message.RPCElement.deserialize(RPCElement.java:262)
	at org.jboss.axis.message.RPCElement.getParams(RPCElement.java:396)
	at org.jboss.axis.client.Call.invoke(Call.java:2662)
	at org.jboss.axis.client.Call.invoke(Call.java:2538)
	at org.jboss.axis.client.Call.invokeInternal(Call.java:1976)
	at org.jboss.axis.client.Call.invoke(Call.java:1914)
	at org.jboss.webservice.client.CallImpl.invoke(CallImpl.java:265)
	at org.jboss.axis.client.AxisClientProxy.invoke(AxisClientProxy.java:381)
	at $Proxy0.runJob(Unknown Source)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:324)
	at org.jboss.webservice.client.PortProxy.invoke(PortProxy.java:105)
	... 4 more


it seems we are getting a result back but are having an issue deserializing the response.  

Has anyone had a similar experience ?
can anyone provide some insight ?
Thanks.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4093164#4093164

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4093164



More information about the jboss-user mailing list