Fix issues where the message's regionDestination was not matching up with the actual region destination it was being deliver from

git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@658776 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Hiram R. Chirino 2008-05-21 17:31:27 +00:00
parent b135f8abad
commit 349466b364
2 changed files with 2 additions and 2 deletions

View File

@ -109,7 +109,7 @@ public class DestinationFilter implements Destination {
for (Iterator iter = destinations.iterator(); iter.hasNext();) { for (Iterator iter = destinations.iterator(); iter.hasNext();) {
Destination dest = (Destination)iter.next(); Destination dest = (Destination)iter.next();
dest.send(context, message); dest.send(context, message.copy());
} }
} }

View File

@ -139,7 +139,7 @@ public abstract class PrefetchSubscription extends AbstractSubscription {
public void add(MessageReference node) throws Exception { public void add(MessageReference node) throws Exception {
synchronized (pendingLock) { synchronized (pendingLock) {
// The destination may have just been removed... // The destination may have just been removed...
if( !destinations.contains(node.getRegionDestination()) ) { if( !destinations.contains(node.getRegionDestination()) && node!=QueueMessageReference.NULL_MESSAGE) {
// perhaps we should inform the caller that we are no longer valid to dispatch to? // perhaps we should inform the caller that we are no longer valid to dispatch to?
return; return;
} }