Announcement Announcement Module
No announcement yet.
pollable ws:outbound-gateway Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • pollable ws:outbound-gateway

    In my application, I have an ws:outbound-gateway that I can send messages to invoke the web service and receive a response. This is however a user invoked process. I'd like to setup the ws:outbound-gateway to be pollable on a cron trigger. I know that I can put a poller element within the ws:outbound-gateway, but I'm a little confused on how to get it working. I need to send an initial XML payload to the web service in order to receive a response back.

    Here's what I've tried so far. I figured I needed to setup a message-factory that produces a request message with the payload I need in order to invoke the web service. However the application won't start because an exception is thrown saying I need a request-channel on my ws:outbound-gateway. For the sake of this example, I'm using a fixed-rate poller instead of a cron based one.

    <ws:outbound-gateway message-factory="outOfServiceRequestFactory"
            <poller max-messages-per-poll="1" fixed-rate="5000"/>
    <service-activator input-channel="outOfServiceCarriersChannel" ref="stringResponseServiceActivator"/>
    Thanks in advance for your help.

  • #2
    Maybe I've misunderstood the polling functionality of a ws:outbound-gateway. After doing a bit of reading, is it the request channel that gets polled and not the actual web service?