So far I have tried to put a wait(2000) in the preProcessDispatch:
@Override
public void preProcessDispatch(MessageDispatch messageDispatch) {
String contentStr = new
String(messageDispatch.getMessage().getContent().getData());
if (pauseThisMsg(contentStr)){
try {
messageDispatch.wait(TIMEOUT);
} catch (InterruptedException e) {
LOGGER.info("preProcessDispatch wait
interrupted.");
}
}
super.preProcessDispatch(messageDispatch);
}
This caused all the messages that should have come later, to not appear at
all on the consumer side.
--
View this message in context:
http://activemq.2283324.n4.nabble.com/Test-harness-to-verify-Message-Order-Preservation-tp4655158p4655406.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.