if(ClusteredQueue.isFromBroker(msg))
{
//if message is from another broker, it should only be delivered
//to another client to meet ordering constraints
Subscription s = super.nextSubscriber(msg);
_logger.info(new LogMessage("Returning next *client* subscriber {0}", s));
if(s == null)
{
//TODO: deliver to another broker, but set the redelivered flag on the msg
//(this should be policy based)
//for now just don't deliver it
return null;
}
else
{
return s;
}
}
Subscription s = _all.nextSubscriber(msg);
_logger.info(new LogMessage("Returning next subscriber {0}", s));
return s;
}