I'm afraid that I understand your query. Can you elaborate on this please ?
My code is:
Message message = consumer.receive(1);
I got 2 messages by order: msg1, msg2, I find sometimes msg1.getJMSTimestamp() > msg2.getTimestamp(), but I send msg1 before msg2.
I refer to the source of JBM-1.4.2, maybe jbm query the queue order by "ORD", which is a field of jbm_msg_ref table, but I cannot got it.
Is there anyway to determine whether I send msg1 before msg2?
A message's timestamp is set on the *client side* before it is sent, not by the server.
The order messages are put in a queue are the order they are received on the server.
So, there's no guarantee that messages in a queue will be in order of timestamp.