10 Replies Latest reply on Jul 1, 2007 10:54 AM by clebert.suconic

    JBMESSAGING-1006 - Throwing exception when failover fails (b

    clebert.suconic

      Discussion of http://jira.jboss.com/jira/browse/JBMESSAGING-1006

      As part of 1006, ChannelSupport:recoverDeliveries will throw an exception if it can't find a delivery to recover on messageRefs.

      This will certainly cause Failover to fail... so the connection that couldn't get a proper failover should be invalidated in such state that no invocation should be made.

      But it happens that a messageConsumer.receive() is going through ok, even if the failover was aborted.

      I have tried few combinations such as closing the connectionDelegate on FailoverCommandCenter, but it didn't work as a close would try to communicate on server.

      So I want to create a method on DelegateSupport, called invalidate, which will be intercepted by ClosedInterceptor and will throw an exception to any call to any Delegate that failed after a failover. This way a call to messageConsumer.receive() would throw a proper exception to the client.

      Let me know if you see any issues.