mirror of https://github.com/apache/activemq.git
https://issues.apache.org/jira/browse/AMQ-5354 - patch applied with thanks
This commit is contained in:
parent
8ab9a56d35
commit
a0c42a61dd
|
@ -1369,13 +1369,16 @@ public abstract class MessageDatabase extends ServiceSupport implements BrokerSe
|
|||
|
||||
Long id = sd.messageIdIndex.get(tx, command.getMessageId());
|
||||
if (id != null) {
|
||||
sd.orderIndex.put(
|
||||
MessageKeys previousKeys = sd.orderIndex.put(
|
||||
tx,
|
||||
command.getPrioritySupported() ? command.getPriority() : javax.jms.Message.DEFAULT_PRIORITY,
|
||||
id,
|
||||
new MessageKeys(command.getMessageId(), location)
|
||||
);
|
||||
sd.locationIndex.put(tx, location, id);
|
||||
if(previousKeys != null) {
|
||||
sd.locationIndex.remove(tx, previousKeys.location);
|
||||
}
|
||||
} else {
|
||||
LOG.warn("Non existent message update attempt rejected. Destination: {}://{}, Message id: {}", command.getDestination().getType(), command.getDestination().getName(), command.getMessageId());
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue