0 Replies Latest reply on Jun 24, 2006 9:23 PM by rfoyle

    Soap:Header element using default namespace [JBoss 4.0.3 Sp

    rfoyle

      Hi,
      I'm developing a webservice that uses soap headers with JBoss 4.0.3 Sp1. I have followed the jboss (test) examples that do not use custom type mappings in the wsdl. The namespace does not appear to be correct in the soap envelope.

      My problem with this approach is that since the output header uses the default namespace it fails xsd validation. Btw: My client works and accesses the webservice.

      I have tried using custom types but that approach does not seem to work (I can share the logs illustrating the NPEs if you want to see them).

      So my question is really centering on using default types, i.e, xsd:string. Is there something I am missing in terms of making the header element namespace aware?

      Here are the relevant snippets.
      wsdl:
      <definitions name="MyWebServiceService" targetNamespace="urn:MyWebService" xmlns:tns="urn:MyWebService" xmlns:ns3="http://somens"
      ...

      ...



      ...

      ...

      <soap:operation soapAction=""/>

      <soap:header message="tns:MyWebService_handleWSRequest" part="header" use="literal" namespace="http://somens" />
      ...
      Soap Envelope (captured in transit)
      <soapenv:Header>
      Default Header value
      </soapenv:Header>
      ...

      What I would expect:
      <soapenv:Header>
      <ns3:header>Default Header value</ns3:header>
      </soapenv:Header>

      Thanks in advance,

      Rich