The WebService is generated from a WSDL via wsdl2java, then deployed. Then a client is also generated by wsdl2java, and invoked. The exception on the server is:
org.apache.cxf.interceptor.Fault: java.lang.ClassCastException@e9f1cb while invoking public void (msg details).
at org.apache.cxf.service.invoker.AbstractInvoker.createFault(AbstractInvoker.java:152)
at org.apache.cxf.jaxws.AbstractJAXWSMethodInvoker.createFault(AbstractJAXWSMethodInvoker.java:83)
at org.apache.cxf.service.invoker.AbstractInvoker.invoke(AbstractInvoker.java:126)
at org.apache.cxf.jaxws.JAXWSMethodInvoker.invoke(JAXWSMethodInvoker.java:55)
and so on..
In the message details I trimmed above follow the method signature (which is OK), and the arguments with which it is invoked. One of the arguments there (2nd or 3rd) fails to be resolved, and is instead moved as LAST argument, with null value, thus breaking the correct sequence of argument types.
I thought it had something to do with XmlGregorianCalendar, and replaced it with Calendar - same error. I then replaced the Calendar with plain
String (and xsd:dateTime with xsd:string) - fails again.
The value that fails to be parsed/read/.. is just an ordinary String.
I intercepted the raw
SOAP message (with a proxy), and it is completely fine there.
CXF 2.2.4 (latest version).