Reputation: 1507
I was trying to find a non-XML (Java Annotation/DSL) example of using timeout as a release strategy, but was unable to do so. (Such as TimeoutCountSequenceSizeReleaseStrategy...)
My goal is to release after some delay since the last correlated entry was added.
Upvotes: 2
Views: 484
Reputation: 121292
What you are looking for is called groupTimeout
. See AbstractCorrelatingMessageHandler.setGroupTimeoutExpression()
.
If you are looking for the solution via annotation, you should consider to use AggregatorFactoryBean
with the @ServiceActivator
and @Bean
annotations.
When we talk about Java DSL, there are groupTimeout()/groupTimeoutExpression()
options on the CorrelationHandlerSpec
when you configure an .aggregate(a -> ...)
in the IntegrationFlow
.
See Reference Manual for more information.
Upvotes: 2