mirror of https://github.com/apache/activemq.git
Improving performance of OrderedPendingList contains method Thanks for David Sitsky for the patch
This commit is contained in:
parent
2aa172f905
commit
673c2928a1
|
@ -162,11 +162,7 @@ public class OrderedPendingList implements PendingList {
|
|||
@Override
|
||||
public boolean contains(MessageReference message) {
|
||||
if (message != null) {
|
||||
for (PendingNode value : map.values()) {
|
||||
if (value.getMessage().equals(message)) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return this.map.containsKey(message.getMessageId());
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue