Reputation: 370
Is there a way to query a Spring Integration channel for the last time it received a message?
Upvotes: 2
Views: 36
Reputation: 24591
Looking at the classes QueueChannel and AbstractPollableChannel, no there isn't.
The only option you have is to rely on message header timestamp
, which is included into each message as its creation time. So if the message was created just before hitting the QueueChannel
(e.g. by passive components like Transformer, Enricher or Gateway) it gives you pretty close time it arrived to your QueueChannel
.
Upvotes: 2