|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Problems with MQPUT while doing Segmentation |
« View previous topic :: View next topic » |
Author |
Message
|
balamurali |
Posted: Thu Sep 04, 2003 4:29 am Post subject: Problems with MQPUT while doing Segmentation |
|
|
Newbie
Joined: 04 Sep 2003 Posts: 4
|
Hello
I have tried to send a 8MB message with segment size of 2MB (4 segments). I am using base java classes of MQSeries. For testing purposes I am trying to read the 8MB file and internally chunking it and then invoking the MQPUT with all the MQPUTOPTIONS as given in the IBM Mq manuals.
I am running it on Windows NT, what I observed is after putting the first two segments (amounting to 4MB) it crashes with the following exception MQJE001: Completion Code 2, Reason 2102 (This is actually insufficient system resources).
I thought this exception is because of the maxmesagelength attribute in the queue and the queue manager I anyway increased it to 10MB. Still the same problem persists. I have pasted the relevant section of the code below. Would greatly appreciate your responses
class NQCalls{
public void putQueue (String host, String appID, String msg, int msgLen, boolean isLastSeq) throws Exception
{
MQMessage mqMsg;
mqMsg = new MQMessage();
mqMsg.setVersion(MQC.MQMD_VERSION_2);
mqMsg.format = MQC.MQFMT_STRING;
//mqMsg.messageType = MQC.MQMT_REQUEST;
mqMsg.applicationIdData = appID;
mqMsg.priority = m_priority;
mqMsg.characterSet = 1208; //UTF-8
mqMsg.write(msg.getBytes("UTF8"));
MQPutMessageOptions pmo = new MQPutMessageOptions();
pmo.options = MQC.MQPMO_LOGICAL_ORDER;
if (m_msgID != null)
mqMsg.messageId = m_msgID.getBytes();
if (isLastSeq)
mqMsg.messageFlags = MQC.MQMF_LAST_SEGMENT | MQC.MQMF_SEGMENTATION_ALLOWED;
else
mqMsg.messageFlags = MQC.MQMF_SEGMENT | MQC.MQMF_SEGMENTATION_ALLOWED;
System.out.println("Before put message");
m_queue.put(mqMsg, pmo);
System.out.println("After put message");
}
}
//The Code which calls to put in the queue
FileChunker aChunker = new FileChunker(fileName); // A piece of code which splits the file into managable byte chunk
byte[] outArray = new byte[FileChunker.CHUNK_SIZE];
for(int i=0;i<aChunker.getNoOfChunks()-1;i++)
{
outArray = aChunker.getNextChunk();
String msg = new String(outArray);
mqCalls1.putQueue("", "APPID", msg,msglen, false);
}
outArray = aChunker.getNextChunk();
String msg = new String(outArray);
mqCalls1.putQueue("", "APPID", msg,msglen,true);
mqCalls1.closeQueue(""); |
|
Back to top |
|
 |
EddieA |
Posted: Thu Sep 04, 2003 6:41 am Post subject: |
|
|
 Jedi
Joined: 28 Jun 2001 Posts: 2453 Location: Los Angeles
|
The manual, for that error, suggests you look at the FDC that was produced for more information.
Cheers, _________________ Eddie Atherton
IBM Certified Solution Developer - WebSphere Message Broker V6.1
IBM Certified Solution Developer - WebSphere Message Broker V7.0 |
|
Back to top |
|
 |
balamurali |
Posted: Thu Sep 04, 2003 7:20 am Post subject: |
|
|
Newbie
Joined: 04 Sep 2003 Posts: 4
|
Can you please clarify on the response. I am not too sure what FDC is all about, where to start looking....
I understand 2102 means it is a problem with Insufficient system Resources, but still not too sure |
|
Back to top |
|
 |
bower5932 |
Posted: Fri Sep 05, 2003 3:24 am Post subject: |
|
|
 Jedi Knight
Joined: 27 Aug 2001 Posts: 3023 Location: Dallas, TX, USA
|
An FDC is a file that MQ produces that has some internal information in it that can point to the specific problem. You find them in one of the errors subdirectors in the /var/mqm file system. Just look for an *.FDC file and you should find one. |
|
Back to top |
|
 |
balamurali |
Posted: Fri Sep 05, 2003 5:07 am Post subject: This is resolved |
|
|
Newbie
Joined: 04 Sep 2003 Posts: 4
|
This was due to a genuine system issue, I tested in a machine with a better RAM it worked fine
Thanks
Bala |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|