Announcement Announcement Module
Collapse
No announcement yet.
outboundChannelAdapter- RC2 Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • outboundChannelAdapter- RC2

    Hello,

    I have a WS OutboundGateway where the response from the webservice is basically sent to a method in a class. Is there a way how this method can receive the response?? Please find below a snippet of my config. Would appreciate help.

    Code:
    <ws:outbound-gateway id="gateway" request-channel="requestChannel" reply-channel="replyChannel" uri="http://localhost:8080/SpringWebServiceGID/"/>
    
    <!--Response from Web Service:fetched data is send to the method-->
    <outbound-channel-adapter channel="replyChannel" ref="replybean" method="receive"/>
    <beans:bean id="replybean" class="integration.GIDIntegration"/>

    public Message<String> receive(){

    //Dont know how to receive the webservice response here
    }

  • #2
    You need to provide a method that accepts an argument (either Message or Message payload). It's just like a void-returning service-activator method.
    Code:
    public void receive(Message<?> message) {...}

    Comment


    • #3
      Hi Mark, Thanks for the response. I agree that the response can be received as an argument but would tht just be enough or should there be any change in the beans config as well?
      Code:
      <beans:bean id="replybean" class="integration.GIDIntegration"/>

      Comment


      • #4
        That should be sufficient if that bean can in fact be created without any constructor arguments or properties.

        Comment

        Working...
        X