Me again ...
Any idea what could be causing the following exception in a
restful_http_binding type snipplet ?
Cheers
Guillaume
21 mai 2007 13:53:27
org.apache.cxf.binding.http.interceptor.URIParameterInInterceptorhandleMessage
INFO: URIParameterInterceptor handle message on path [/books/123] with
content-type [null]
21 mai 2007 13:53:27 org.apache.cxf.phase.PhaseInterceptorChain doIntercept
INFO: Interceptor has thrown exception, unwinding now
java.lang.ClassCastException:
org.apache.ws.commons.schema.XmlSchemaComplexType
at
org.apache.cxf.binding.http.interceptor.URIParameterInInterceptor.mergeParams
(URIParameterInInterceptor.java:122)
at
org.apache.cxf.binding.http.interceptor.URIParameterInInterceptor.handleMessage
(URIParameterInInterceptor.java:103)
at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(
PhaseInterceptorChain.java:148)
at org.apache.cxf.transport.ChainInitiationObserver.onMessage(
ChainInitiationObserver.java:63)
at
org.apache.cxf.transport.http_jetty.JettyHTTPDestination.serviceRequest(
JettyHTTPDestination.java:200)
at
org.apache.cxf.transport.http_jetty.JettyHTTPDestination.doService(
JettyHTTPDestination.java:161)
at org.apache.cxf.transport.http_jetty.JettyHTTPHandler.handle(
JettyHTTPHandler.java:54)
at org.mortbay.jetty.handler.ContextHandler.handle(
ContextHandler.java:690)
at org.mortbay.jetty.handler.ContextHandlerCollection.handle(
ContextHandlerCollection.java:191)
at org.mortbay.jetty.handler.HandlerWrapper.handle(
HandlerWrapper.java:139)
at org.mortbay.jetty.Server.handle(Server.java:285)
at org.mortbay.jetty.HttpConnection.handleRequest(
HttpConnection.java:457)
at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(
HttpConnection.java:751)
at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:500)
at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:209)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:357)
at org.mortbay.io.nio.SelectChannelEndPoint.run(
SelectChannelEndPoint.java:329)
at org.mortbay.thread.BoundedThreadPool$PoolThread.run(
BoundedThreadPool.java:475)
On 5/17/07, tog <[EMAIL PROTECTED]> wrote:
Hiya
I got the following exception when querying the following URL of a
modified version of the restful_http_binding sample.
<ns1:XMLFault>
<ns1:faultstring>
java.lang.ClassCastException :
org.apache.ws.commons.schema.XmlSchemaComplexType
</ns1:faultstring>
</ns1:XMLFault>
The only change I made between this faulty version and a working one is
about the GetBook class that was rewriten and compiled in Groovy. The
schema generated in now
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<xs:schema elementFormDefault="qualified" version=" 1.0" targetNamespace="
http://book.acme.com" xmlns:xs=" http://www.w3.org/2001/XMLSchema">
<xs:complexType name="getBook">
<xs:sequence>
<xs:element name="id" type="xs:long"/>
</xs:sequence>
</xs:complexType>
</xs:schema>
instead of
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<xs:schema elementFormDefault="qualified" version="1.0" targetNamespace="
http://book.acme.com" xmlns:tns=" http://book.acme.com"
xmlns:xs="http://www.w3.org/2001/XMLSchema
">
<xs:element name="GetBook" type="tns:getBook"/>
<xs:complexType name="getBook">
<xs:sequence>
<xs:element name="id" type="xs:long"/>
</xs:sequence>
</xs:complexType>
</xs:schema>
would these changes lead to that error ? My feeling is *no* since I did
the same change for other classes and this did not cause the same exception.
Thoughts ?
Cheers
Guillaume