ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » IBM MQ API Support » xms queuebrowser not retrieving large (>256k) messages

Post new topic  Reply to topic Goto page Previous  1, 2
 xms queuebrowser not retrieving large (>256k) messages « View previous topic :: View next topic » 
Author Message
jefflowrey
PostPosted: Mon Jul 23, 2007 8:46 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

So your problem is that if you have a queue with a single, committed, message that is larger than 256K in size, and you start up your program for the first time, then hasNext() returns false?
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
antishok
PostPosted: Mon Jul 23, 2007 8:48 am    Post subject: Reply with quote

Apprentice

Joined: 29 Apr 2007
Posts: 31

To make things clearer -

notice where I wrote *** ,
- in the first case, this number is 260000, the queue is initially empty, and when i run it, the message is written (size on queue is indeed 260000) and then read, works fine

- in the second case (seperate run), i change this number to 262000 (or anything larger), the message is written as before (just its a bit bigger),
but hasNext() returns false this time

the ONLY difference was the message size

The queue is initially empty in both cases, and each case is run seperately

Code:

xms::InitialContext i;
i.create("file://c:\\Program Files\\IBM\\JMSAdmin Tool\\cds\\.bindings");
d = dynamic_cast<xms::Destination *>(i.lookup("outgoingContentQueue2"));

         xms::MessageProducer p = m_sess.createProducer(*d);
         xms::TextMessage t = m_sess.createTextMessage();
         xmsSBYTE buf[300000];
         memset(buf, 'A', 300000);
         t.setText(xms::String(buf,***260000***));  // 260000 or 262000
         p.send(t);
         p.close();

         /*xms::QueueBrowser*/ receiver = m_sess.createBrowser(*d);

xms::Iterator i = receiver.getEnumeration();
if ( i.hasNext() == xmsTRUE )
{ // in the first case xmsTRUE was returned, in the second case xmsFALSE...}



Hope it's clear now.
Back to top
View user's profile Send private message
antishok
PostPosted: Mon Jul 23, 2007 8:50 am    Post subject: Reply with quote

Apprentice

Joined: 29 Apr 2007
Posts: 31

jeff, yes, that's the problem,

although, the threshold is not exactly 256k,
it's somewhere between 261754 and 261781 (which are a bit less than 256k),
i'm guessing this adds up to 256k with header overhead or what not

(the code i posted above also writes the message to the queue, just for demonstrating to you. my intention is for another process to write the messages, but that's besides the point here)
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Mon Jul 23, 2007 8:55 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Can you compare the results of amqsbcg between the smaller working message and the larger non-working message?
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
antishok
PostPosted: Mon Jul 23, 2007 9:08 am    Post subject: Reply with quote

Apprentice

Joined: 29 Apr 2007
Posts: 31

I get a MQRC_TRUNCATED_MSG_FAILED on both sizes (260000 and 262000) with amqsbcg:

MQGET 1, failed with CompCode:1 Reason:2080
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Mon Jul 23, 2007 9:13 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Interesting!

What happens when your program tries to browse a msg > 256K created by something like RFHUTIL?
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
antishok
PostPosted: Mon Jul 23, 2007 9:32 am    Post subject: Reply with quote

Apprentice

Joined: 29 Apr 2007
Posts: 31

small message (240000) was read fine,
large message (280000) was not (hasNext returned false)

written by RFHUTIL..
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Mon Jul 23, 2007 9:42 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981



You probably should open a PMR.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
antishok
PostPosted: Mon Jul 23, 2007 9:50 am    Post subject: Reply with quote

Apprentice

Joined: 29 Apr 2007
Posts: 31

I suppose I will
thank you for your efforts and quick replies
Back to top
View user's profile Send private message
antishok
PostPosted: Mon Jul 30, 2007 5:33 am    Post subject: Reply with quote

Apprentice

Joined: 29 Apr 2007
Posts: 31

This was indeed a bug,
IBM are working on a fix.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Goto page Previous  1, 2 Page 2 of 2

MQSeries.net Forum Index » IBM MQ API Support » xms queuebrowser not retrieving large (>256k) messages
Jump to:  



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
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.