1

i'm developing soap app using Spring + SOAP+JAXB+XSD

i want to do customize the soap header

My Existing response

<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
   <SOAP-ENV:Header/>
   <SOAP-ENV:Body>
  <ns2:StudentResponse xmlns:ns2="http://studentinfo.com/">
  </ns2:StudentResponse>

My Expected response

<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:stu="http://studentinfo.com/">
   <SOAP-ENV:Header/>
   <SOAP-ENV:Body>
  <ns2:StudentResponse xmlns:ns2="http://studentinfo.com/">
  </ns2:StudentResponse>

Note that xmlns:stu="http://studentinfo.com/" is in my soap envelop header, could you please advise how to add this? i'm testing soap using SOAP UI, which fails to validate the request and response headers using assertions.

Please advise

Thanks

4

0 回答 0