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 » WebSphere Message Broker (ACE) Support » Generate new MQMD.MsgId in eSQL without writing to Queue?

Post new topic  Reply to topic
 Generate new MQMD.MsgId in eSQL without writing to Queue? « View previous topic :: View next topic » 
Author Message
Ramphart
PostPosted: Fri Aug 21, 2009 9:54 am    Post subject: Generate new MQMD.MsgId in eSQL without writing to Queue? Reply with quote

Disciple

Joined: 21 Jul 2004
Posts: 150
Location: South Africa, JHB

- Windows Platform
- Message Broker 6.1 (Ver 6.1.0.1)
- Toolkit 6.1.0

Hi,

Is there a way to generate a unique MQMD.MsgId in esql code WITHOUT putting the message to a queue eventually?

I use to develop flows which gets its original (incoming) message from an Input Queue and hence always had a message ID to work with. In the new requirement my messages will come in via a SOAPInput node.

I have a flow: SOAPInput -> AddMQMD_ComputeNode -> Subflow(Log To DB) -> Transform_ComputeNode -> SendToExternalSystem -> Subflow(Log To DB)
[Also a SOAPReply within the flow but node important for this issue]

I have a Subflow(Log To DB) used throughout our flows / environment which logs messages to our database. One of the fields logged is the MQMD.MsgId of messages as is pass through the flows and the system in general.

I need to generate a unique MsgId at the point where I get the SOAP Message as I need to log the incoming message to the database before we do transformation etc on it and later within the flow the same MsgId would also be used to logged subsequent transformed messages.

I'll always get a X'000000....' MsgId if I do the following:
Set OutputRoot.MQMD.MsgId = MQMI_NONE;
within the AddMQMD Compute node which is not the desired result.

Is there any way / function to generate a proper MsgId WITHOUT me having to write the message to an output queue?

Thanks in advance for any assistance.

Regards
Ramo
_________________
Applications Architect
Back to top
View user's profile Send private message
Vitor
PostPosted: Fri Aug 21, 2009 10:02 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

Not a msgId (or a default msgId) but you could use the UUID functions to generate an id.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Fri Aug 21, 2009 1:43 pm    Post subject: Reply with quote

Grand High Poobah

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

You could also write a dummy message to a queue with a very short expiry, so the queue would never fill up. With a create new msgid on the output node you could then retrieve the msgid from the local environment and have your ID at the right format...

Have fun
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
WMBDEV1
PostPosted: Sat Aug 22, 2009 1:10 pm    Post subject: Reply with quote

Sentinel

Joined: 05 Mar 2009
Posts: 888
Location: UK

Vitor wrote:
Not a msgId (or a default msgId) but you could use the UUID functions to generate an id.


The problems you are facing are caused because of your reliance on the behaviour of a particular technology (in this case MQ). If you can resize the DB field it should be possible to use something like uuidaschar or even get the underlying DBMS to generate values for you.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Generate new MQMD.MsgId in eSQL without writing to 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.