Announcement Announcement Module
No announcement yet.
Redirect to another target Url in EndpointInterceptor Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • Redirect to another target Url in EndpointInterceptor


    in the soap header of a client's message call to my web service is given a specific different target url which I have to send the response message to. So the soap header of the request message looks like this:

    <soapenv:Envelope ...>
    </soapenv:Envelope ...>

    How can I redirect my response to that different target url in <ReplyTo><address> ? My solution till now is a EndpointInterceptor which makes in the method handleResponse a Web Service call by using

    WebServiceTemplate webServiceTemplate = new WebServiceTemplate();
    StreamSource source = new StreamSource(new StringReader(responseMessage.toString()));
    StreamResult result = new StreamResult();
    webServiceTemplate.sendSourceAndReceiveToResult(ad dress, source, result);
    return false; // to omit the direct response of spring to requestUrl

    Is there another solution for that problem ? Sorry I'm newbie to spring ws...