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 » General Discussion » Creation of an unique messageID before sending a message

Post new topic  Reply to topic
 Creation of an unique messageID before sending a message « View previous topic :: View next topic » 
Author Message
ste
PostPosted: Wed Jun 09, 2004 6:51 am    Post subject: Creation of an unique messageID before sending a message Reply with quote

Newbie

Joined: 27 May 2004
Posts: 5

Hi

I know that it is possible to ask the QueueManager to create a new unique ID for the message I'm sending, specifying the MQPMO_NEW_MSG_ID flag in the put option.

I would like to ask if there is a way to for a new unique ID before sending any message.

Thanks in advance,
Steve
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Wed Jun 09, 2004 6:55 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

What have you tried?
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
ste
PostPosted: Wed Jun 09, 2004 7:05 am    Post subject: Reply with quote

Newbie

Joined: 27 May 2004
Posts: 5

I my scenario I have a database of messages which shall be sent to a queue.

I have a component which interface my system to MQSeries queues.

I would like to associate my messages with unique IDs before passing them to this component which shall send them. This component shall copy thess IDs in the messages.

If something goes wrong and the component crashes after having sent a message but before having replied to me, I would think that the message wasn't delivered.

Using this ID I can check if a message already exists in the queue before sending it again.
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Wed Jun 09, 2004 7:19 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

ste wrote:
If something goes wrong and the component crashes after having sent a message but before having replied to me, I would think that the message wasn't delivered.

Why would you think that? Because the component doesn't give you an unambiguous response in this respect?

ste wrote:
Using this ID I can check if a message already exists in the queue before sending it again.

How? By browsing the queue for a particular message id? What if the message has been put by the component, and then gotten by the receiving application already? What if the queue is a remote queue?

You should read the Application Programming Guide, particularly some of the sections on transactions.

You appear to be trying to solve a problem in a poor way that is already solved for you with two-phase commit or even plain MQSeries transactions.

And, this is the wrong forum for this question.

And, again, What Have You Tried?
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
ste
PostPosted: Wed Jun 09, 2004 10:48 pm    Post subject: Reply with quote

Newbie

Joined: 27 May 2004
Posts: 5

Ok,
Thank you for your advise.
You're perfectly right... It doesn't make sense.
Steve

p.s.
Actually I haven't tried anything at the moment.

p.p.s.
Which is the correct forum for question like this?
Back to top
View user's profile Send private message
Michael Dag
PostPosted: Wed Jun 09, 2004 10:58 pm    Post subject: Reply with quote

Jedi Knight

Joined: 13 Jun 2002
Posts: 2607
Location: The Netherlands (Amsterdam)

Moved to General Discussion
_________________
Michael



MQSystems Facebook page
Back to top
View user's profile Send private message Visit poster's website MSN Messenger
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » General Discussion » Creation of an unique messageID before sending a message
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.