Permalink
Browse files

Add override DefaultConsumer.handleCancel to log when broker notifies…

… of cancel. This happens when queue is deleted or when mirrored slave queue is promoted to master.
  • Loading branch information...
1 parent 5a8fb09 commit 187eb30066ee8125932866756a553d2ac95b2e92 Dave Stevens committed Jan 20, 2012
@@ -231,6 +231,15 @@ public void handleShutdownSignal(String consumerTag, ShutdownSignalException sig
deliveryTags.clear();
}
+ @Override
+ public void handleCancel(String consumerTag) {
+ if (logger.isDebugEnabled()) {
+ logger.debug("Received cancellation notice for " + BlockingQueueConsumer.this);
+ }
+ // Signal to the container that we have been cancelled
+ activeObjectCounter.release(BlockingQueueConsumer.this);
+ }
+
@Override
public void handleCancelOk(String consumerTag) {
if (logger.isDebugEnabled()) {

0 comments on commit 187eb30

Please sign in to comment.