Announcement Announcement Module
Collapse
No announcement yet.
Pub-Sub error handling strategy Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Pub-Sub error handling strategy

    Here is my channels set-up:
    1. A jdbc message-store backed queue
    2. A bridge connecting the queue to a pub-sub channel
    3. The poller configured on the pub-sub channel is transactional

    Now when there is an exception raised in any one of the subscribers then the transaction rolls back and the message is retried for ever. The message is again processed by all the subscribers again. If this is a permanent exception in at least subscriber then the message is not getting processed by none of the other subscribers.

    What is the best exception handling strategy here?
    I prefer exception handling on the subscriber i.e.only the failing subscriber will retry, other subscribers will process the message and move on.
    How can this be implemented in spring integration

  • #2
    More details here..

    1. If the poller is made transactional and the message fails processing in at least one of the subscribers, then the message is rolled back to the message store and retried. I also configured a jdbc message store for the errorChannel. Every time the message processing fails, the message gets rolled back to the original message store and the error channel message store has one entry for each retry.

    2. If the poller is made non-transactional and the message fails processing in the first subscriber, then the message is put to the error channel, but the second subscriber never gets the message.

    It appears that there is something fundamentally wrong.. Is it with my configuration?

    Comment

    Working...
    X