Revert "[AMQ-7314] Fix counter increment when lastDelivereSeqId > BrokerSequenceId"

This reverts commit df1750fe01.
This commit is contained in:
jbonofre 2020-03-10 06:29:08 +01:00
parent 265fd65328
commit 1550ae42f7
1 changed files with 2 additions and 2 deletions

View File

@ -541,11 +541,11 @@ public class Queue extends BaseDestination implements Task, UsageListener, Index
// locate last redelivered in unconsumed list (list in delivery rather than seq order)
if (lastDeliveredSequenceId > RemoveInfo.LAST_DELIVERED_UNSET) {
for (MessageReference ref : unAckedMessages) {
LOG.debug("UnAck reference message id: {}, reference message broker sequence id: {}", ref.getMessageId(), ref.getMessageId().getBrokerSequenceId());
if (lastDeliveredSequenceId == 0 || (lastDeliveredSequenceId > 0 && ref.getMessageId().getBrokerSequenceId() <= lastDeliveredSequenceId)) {
if (ref.getMessageId().getBrokerSequenceId() == lastDeliveredSequenceId) {
lastDeliveredRef = ref;
markAsRedelivered = true;
LOG.debug("found lastDeliveredSeqID: {}, message reference: {}", lastDeliveredSequenceId, ref.getMessageId());
break;
}
}
}