ws-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Philippe Langevin <plange...@ctecworld.com>
Subject XmlObject parameter to XmlRPC call
Date Tue, 08 Mar 2011 20:25:34 GMT
Hi,

I'm trying to pass an org.apache.xmlbeans.XmlObject as a parameter to a call to an apache
XmlRpc server.  The server fail and generate the exception at the bottom of this message.

Some info :
- Server under tomcat6
- Using a custom Handler Mapping
- Calling through interfaces (With the mapping)

Actually, the mapping works for many other functions with

Here is the handler mapping initialisation :
protected XmlRpcHandlerMapping newXmlRpcHandlerMapping() throws XmlRpcException {
      PropertyHandlerMapping phm = new PropertyHandlerMapping() ;

      phm.addHandler(ctec.TVLMManager.XmlRpc.TestServer.class.getName(), ctec.TVLMManager.XmlRpc.server.TestServerImpl.class)
;
      phm.addHandler(ctec.TVLMManager.XmlRpc.TVLMServer.class.getName(), ctec.TVLMManager.XmlRpc.server.TVLMServerImpl.class)
;

      return phm ;
}

I also tried adding a custom TypeFactory in the newXmlRpcServer(...) but the getParser(...)
method is never called.  On the client side, the getSerializer(...) is called.
protected XmlRpcServletServer newXmlRpcServer(ServletConfig pConfig) throws XmlRpcException
{
      XmlRpcServletServer server = super.newXmlRpcServer(pConfig);
      server.setTypeFactory(new CustomTypeFactory(server)) ;

      return server ;
}

java.lang.IllegalStateException: Invalid parameter or result type: org.apache.xmlbeans.XmlObject
        at org.apache.xmlrpc.common.TypeConverterFactoryImpl.getTypeConverter(TypeConverterFactoryImpl.java:296)
        at org.apache.xmlrpc.server.ReflectiveXmlRpcHandler$MethodData.<init>(ReflectiveXmlRpcHandler.java:47)
        at org.apache.xmlrpc.server.ReflectiveXmlRpcHandler.<init>(ReflectiveXmlRpcHandler.java:73)
        at org.apache.xmlrpc.metadata.ReflectiveXmlRpcMetaDataHandler.<init>(ReflectiveXmlRpcMetaDataHandler.java:54)
        at org.apache.xmlrpc.server.AbstractReflectiveHandlerMapping.newXmlRpcHandler(AbstractReflectiveHandlerMapping.java:188)
        at org.apache.xmlrpc.server.AbstractReflectiveHandlerMapping.registerPublicMethods(AbstractReflectiveHandlerMapping.java:169)
        at org.apache.xmlrpc.server.PropertyHandlerMapping.addHandler(PropertyHandlerMapping.java:111)
        at ctec.TVLMManager.XmlRpc.server.TVLMXmlRpcServlet.getPropertyHandlerMapping(TVLMXmlRpcServlet.java:74)
        at ctec.sdk.xmlrpc.CTecXmlRpcServlet.newXmlRpcHandlerMapping(CTecXmlRpcServlet.java:42)
        at org.apache.xmlrpc.webserver.XmlRpcServlet.init(XmlRpcServlet.java:99)
        at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1173)
        at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:809)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:129)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
        at org.apache.catalina.authenticator.SingleSignOn.invoke(SingleSignOn.java:394)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
        at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:857)
        at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:588)
        at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)
        at java.lang.Thread.run(Thread.java:636)

Mime
View raw message