cxf-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kdesin <kartheekdesine...@gmail.com>
Subject Re: VOTE: Extend CXF to support JAX-RPC - Good work
Date Fri, 06 Jul 2012 11:33:45 GMT
Hi all,

I deeply wish that there is support for JAX-RPC from the current
implementation of CXF:

I am in a situation where I need to consume a JAX-RPC webservice using
JAX-WS support.

I know that migrating to JAX-WS entirely is the best option but due to some
vendor issues we cannot do that.

I have come across the Dispatch API in JAX-WS to achieve this.(Our services
layer runs on CXF so I am forced to go via this route)

All I am trying is to write a standalone client to invoke the RPC service
and display the output.

Please let me know how to resolve this error:

Service service = Service.create(url, SERVICE);
 javax.xml.ws.Dispatch dispatch =
service.createDispatch(GatewaySoapPort,javax.xml.transform.Source.class,
Service.Mode.PAYLOAD); Source req = new StreamSource("rpc.xml"); 
Source res = dispatch.invoke(req); /*Error at this point*/

Exception:

Exception in thread "main" javax.xml.ws.WebServiceException:
java.lang.IllegalStateException: Current event not START_ELEMENT or
END_ELEMENT at
com.sun.xml.ws.encoding.soap.client.SOAPXMLDecoder.toInternalMessage(SOAPXMLDecoder.java:263)
at
com.sun.xml.ws.protocol.soap.client.SOAPMessageDispatcher.receive(SOAPMessageDispatcher.java:545)
at
com.sun.xml.ws.protocol.soap.client.SOAPMessageDispatcher.doSend(SOAPMessageDispatcher.java:288)
at
com.sun.xml.ws.protocol.soap.client.SOAPMessageDispatcher.send(SOAPMessageDispatcher.java:153)
at
com.sun.xml.ws.client.dispatch.impl.DispatchDelegate.send(DispatchDelegate.java:71)
at
com.sun.xml.ws.client.dispatch.DispatchBase.sendAndReceive(DispatchBase.java:308)
at com.sun.xml.ws.client.dispatch.DispatchBase.invoke(DispatchBase.java:133)

-----
Saludos
Kartheek
--
View this message in context: http://cxf.547215.n5.nabble.com/Re-VOTE-Extend-CXF-to-support-JAX-RPC-Good-work-tp547563p5710671.html
Sent from the cxf-user mailing list archive at Nabble.com.

Mime
View raw message