Spring element delay integration

I'm trying to set up a spring integration and I want to use an element that is basically between the retryFilter and the queue.

Everything works fine if I go straight from the retryFilter to the queue, however, as soon as I put a delay element in between the config file cannot be loaded (as it does when there is an error in it).

The configuration for this section looks like this:

 <!-- Retry filter -->
 <filter
  input-channel="retryChannel"
  ref="retryFilter"
  method="doRetry" 
  output-channel="queueChannel" />

 <channel id="delayChannel" />

 <delayer input-channel="delayChannel" default-delay="10000" output-channel="queueChannel"/>

 <channel id="queueChannel">
  <queue capacity="100" />
 </channel>

    <poller id="poller" default="true">
        <interval-trigger interval="1000"/>
    </poller>

      

Any help is greatly appreciated.

Dave

+2


source to share


1 answer


I tried your sample and it worked great on Spring Integration 2.0.0.BUILD-SNAPSHOT. You can see my commit here:

http://github.com/iwein/Spring-Integration-Sandbox/commit/c274a12f057b6750dcf18663486a99970368e68e

There are a couple of things that I changed:



  • channel renames (in, out) instead of longer names
  • filter outputs delay input, instead of passing by delay

Perhaps you are using an older version of Spring Integration?

You can check out my little gradle project ( http://github.com/iwein/Spring-Integration-Sandbox/tree/master/quick-samples/router-test/ ) which can help you experiment. If you still can't get it to work, it would be nice if you split the stack and the exact version you are using.

+2


source







All Articles