When investigating a MQ JMS performance problem, I noticed that there was a pattern of
MQGET – 2080 (0820) (RC2080): MQRC_TRUNCATED_MSG_FAILED
followed by an MQGET with a bigger buffer which worked.
Being a performance person these double gets did not look right to me.
I spoke to Paul Titheridge of IBM who said this was fixed back in MQ V6 with a java property
If you specify
in the Java start-up you will get an 8KB buffer instead of the default 4KB.
Easy when you know how!
2 thoughts on “Why is my java application doing multiple gets because the receive buffer is too small?”
I would suggest that the best value for com.ibm.mq.jmqi.defaultMaxMsgSize is to use the value for “Maximum Message Length” (MAXMSGL) queue attribute from the particular queue that the code is doing the MQGET on.