1 Reply Latest reply on Jan 22, 2006 3:14 PM by thomas.diesler

    Cannot find jaxrpc-mapping for type

    bbell2000

      Using JBoss 4.0.3SP1 w/JWSDP 1.6

      My WSDL looks like this:

      <definitions
       xmlns="http://schemas.xmlsoap.org/wsdl/"
       xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
       xmlns:http="http://schemas.xmlsoap.org/wsdl/http/"
       xmlns:xs="http://www.w3.org/2001/XMLSchema"
       xmlns:m="urn:xmlns:example.com:test:common:msg-types:2006-01"
       xmlns:uc="urn:xmlns:example.com:test:common:2006-01"
       targetNamespace="urn:xmlns:example.com:test:common:2006-01">
       <types>
       <xs:schema>
       <xs:import namespace="urn:xmlns:example.com:test:msg-types:2006-01" schemaLocation="Messages.xsd"/>
       </xs:schema>
       </types>
       <message name="TestRequest">
       <part name="msg" element="m:TestRequest"/>
       </message>
       <message name="TestResponse">
       <part name="msg" element="m:TestResponse"/>
       </message>
       ... snipped for brevity
      </definitions>
      


      Note that the targetNamespace for my web service and the targetNamespace of my schema are different and that the elements I use in my messages are defined in my schema.

      My jaxrpc mapping generated by wscompile looks like this:

      <service-endpoint-method-mapping>
      <java-method-name>Test</java-method-name>
      <wsdl-operation>Test</wsdl-operation>
      <method-param-parts-mapping>
      <param-position>0</param-position>
      <param-type>javax.xml.soap.SOAPElement</param-type>
      <wsdl-message-mapping>
      <wsdl-message xmlns:wsdlmsgns="urn:xmlns:example.com:test:common:2006-01">
      wsdlMsgNS:TestRequest</wsdl-message>
      <wsdl-message-part-name>msg</wsdl-message-part-name>
      <parameter-mode>IN</parameter-mode>
      </wsdl-message-mapping>
      </method-param-parts-mapping>
      <wsdl-return-value-mapping>
      <method-return-value>javax.xml.soap.SOAPElement</method-return-value>
      <wsdl-message xmlns:wsdlmsgns="urn:xmlns:example.com:test:common:2006-01">
      wsdlMsgNS:TestResponse</wsdl-message>
      <wsdl-message-part-name>msg</wsdl-message-part-name>
      </wsdl-return-value-mapping>
      </service-endpoint-method-mapping>
      


      When I deploy the web service, JBoss generates the following error:

      [org.jboss.webservice.metadata.jaxrpcmapping.JavaWsdlMapping] Cannot find jaxrpc-mapping for type: {urn:xmlns:example.com:test:common:msg-types:2006-01}TestResponse
      [org.jboss.webservice.deployment.ServiceDescription] Guessing the javaType from typeQName: {urn:xmlns:example.com:test:common:msg-types:2006-01}TestResponse -> javax.xml.soap.TestResponse
      


      Why is JBoss looking for my message in the wrong namespace?

      I've also tried deploying the following ws4ee-deployment.xml...

      <deployment
       xmlns="http://xml.apache.org/axis/wsdd/"
       xmlns:java="http://xml.apache.org/axis/wsdd/providers/java"
       xmlns:soap="http://schemas.xmlsoap.org/soap/encoding/"
       xmlns:xsi="http://www.w3.org/2000/10/XMLSchema-instance"
       xmlns:xsd="http://www.w3.org/2001/XMLSchema">
       <typemapping
       qname="m:BeginAuthenticationRequest"
       xmlns:m="urn:xmlns:example.com:test:common:msg-types:2006-01"
       type="java:javax.xml.soap.SOAPElement"
       serializer="org.jboss.axis.encoding.ser.ElementSerializerFactory"
       deserializer="org.apache.axis.encoding.ser.ElementDeserializerFactory"
       encodingstyle=""></typemapping>
       <typemapping
       qname="m:AuthenticationResponse"
       xmlns:m="urn:xmlns:example.com:test:common:msg-types:2006-01"
       type="java:javax.xml.soap.SOAPElement"
       serializer="org.jboss.axis.encoding.ser.ElementSerializerFactory"
       deserializer="org.apache.axis.encoding.ser.ElementDeserializerFactory"
       encodingstyle=""></typemapping>
      </deployment>
      


      ... and that didn't work either.

      Any and all suggestions would be most appreciated.


        • 1. Re: Cannot find jaxrpc-mapping for type
          thomas.diesler

           


          <message name="TestResponse">
          <part name="msg" element="m:TestResponse"/>
          </message>


          actually resolves to

          {urn:xmlns:example.com:test:common:msg-types:2006-01}TestResponse
          


          There should be type mapping for this in jaxrpc-mapping and the associated java wrapper type should be in the deployment