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 Java / JMS » Problems getting multiple messages from a queue

Post new topic  Reply to topic Goto page Previous  1, 2
 Problems getting multiple messages from a queue « View previous topic :: View next topic » 
Author Message
KeithPark
PostPosted: Thu Jun 09, 2005 6:13 am    Post subject: Reply with quote

Apprentice

Joined: 12 Nov 2002
Posts: 25

Hi

Latest update on this problem is that the corruption is size related.

When a the messages being posted are less than 4Kb then they are read correctly, however, once the message size creeps above that magic number then the second starts to corrupt the first.

When it was running correctly it was recovering the messages in the correct order.

Keith
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Thu Jun 09, 2005 7:37 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

4Kb, or 4Mb?

My test code works fine for me when I run against 14kb messages.
****************
EDIT
****************

No. It doesn't!

It shows the exact same behavior... (It always helps to test with *different* data )
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Thu Jun 09, 2005 12:11 pm    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

Never seen this type of behavior. But then I am nearly always using JMS...
Back to top
View user's profile Send private message Send e-mail
KeithPark
PostPosted: Mon Jun 13, 2005 6:54 am    Post subject: Reply with quote

Apprentice

Joined: 12 Nov 2002
Posts: 25

Latest breaking news...

A work around solution has been found.

When the message is read from the queue I am now reading the data into a byte array which I then use to populate a second message which is placed into the array. This is messy, but provides the decoupling which appears to be required.

Code:
                    int msgLen = theMessage.getMessageLength () ;
                    
                    System.out.println("Message Length = " + msgLen);
                    byte [] msgData = new byte [msgLen] ;
                    theMessage.readFully (msgData) ;
                
                    MQMessage mqMsg = new MQMessage();
                    mqMsg.write(msgData,0,msgLen);

                    vMessages.addElement((Object)mqMsg);


Back to top
View user's profile Send private message
jefflowrey
PostPosted: Mon Jun 13, 2005 6:58 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Did you open a PMR with IBM?
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
KeithPark
PostPosted: Mon Jun 13, 2005 7:02 am    Post subject: Reply with quote

Apprentice

Joined: 12 Nov 2002
Posts: 25

Yep.

PMR is open & still chasing them to provide a real solution.

Back to top
View user's profile Send private message
KeithPark
PostPosted: Thu Jun 16, 2005 4:52 am    Post subject: Reply with quote

Apprentice

Joined: 12 Nov 2002
Posts: 25

Latest update...

IBM have agreed that this is a problem with the CSD 9 jars and have given me a fix to test.

Back to top
View user's profile Send private message
jefflowrey
PostPosted: Thu Jun 16, 2005 4:55 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

KeithPark wrote:
Latest update...

IBM have agreed that this is a problem with the CSD 9 jars and have given me a fix to test.



Tell them it is also a problem with the v6 Beta jars, as well.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
PeterPotkay
PostPosted: Sat Jun 18, 2005 10:06 am    Post subject: Reply with quote

Poobah

Joined: 15 May 2001
Posts: 7722

Is this the same problem?

http://www-1.ibm.com/support/docview.wss?rs=172&context=SW900&dc=DB550&uid=swg1IY72849&loc=en_US&cs=utf-8&lang=en
_________________
Peter Potkay
Keep Calm and MQ On
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Sat Jun 18, 2005 5:55 pm    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

PeterPotkay wrote:
Is this the same problem?

http://www-1.ibm.com/support/docview.wss?rs=172&context=SW900&dc=DB550&uid=swg1IY72849&loc=en_US&cs=utf-8&lang=en


Yes.

I would have hoped that such things would not have been in the v6 beta.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
KeithPark
PostPosted: Wed Jun 29, 2005 12:35 am    Post subject: Reply with quote

Apprentice

Joined: 12 Nov 2002
Posts: 25

Quote:
I would have hoped that such things would not have been in the v6 beta.


I have notified the chaps who provided my fix that they need to take a look at the V6 beta release as well.

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 Java / JMS » Problems getting multiple messages from a queue
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.