Sep 12th, 2010, 11:20 AM
Graceful stopping of Inbound Channel Adapter
I have been looking for suggestions to implement a graceful shutdown of an inbound channel adapter (file). Have come across some earlier Jira issues on similar topics, but could not find any concrete solution yet.
My SI implementation is a simple flow :
- with an inbound channel adapter and a synchronous processing of the received message with mostly Direct Channels.
- after all the processing is done the message is delivered to a QueueChannel with queue capacity 1.
- the final endpoint is a service-activator/gateway which polls the queue channel at regular intervals and picks up any message from the final Queue Channel.
Now I need to implement a shutdown process for the inbound channel adapter, and make sure that the last message is processed before the actual stop(). Obviously the current SI implementation is sending the last message to the exception processing (as expected).
Please feel free to ask for any further clarifications.
Any suggestions will be highly appreciated.
Tags for this Thread