Announcement Announcement Module
Collapse
No announcement yet.
Is it possible to set dynamic reply-timeout to Producer to wait consumer's response? Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Is it possible to set dynamic reply-timeout to Producer to wait consumer's response?

    Hi Guys,

    I am curious about will it possible to let Producer set a dynamic reply-timeout for waiting consumer's response?

    Currently, as each time consumer used different time to finish its job. Some time it's quick(few hours) some time it cost long time(longer than 1 day). Now I just set extreme long fixed time let producer wait for consumer's response. But as system required that if producer can according to each consumer to set appropriate wait time, that will be great! How to implement this feature?

    The system using AsynchronousGateway. And it uses one system as producer through outboundGateway sending out its request, the other system is the consumer which use inboundGateway to receive and process message that once finish job will return back to producer.

  • #2
    It's not currently possible to set the timeout on a per-request basis.

    Probably the easiest way to do what you want is to add multiple methods to the async gateway and use the appropriate method...

    Code:
    	<int:gateway id="gw" service-interface="foo.MyGateway"
    			default-request-channel="input">
    		<int:method name="sendFast" reply-timeout="5000" />
    		<int:method name="sendSlow" reply-timeout="60000" />
    	</int:gateway>

    Comment


    • #3
      Thanks for your quick reply, it is very helpful.

      Comment

      Working...
      X