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 » Is a Route To Message Flow Multi-threaded?

Post new topic  Reply to topic
 Is a Route To Message Flow Multi-threaded? « View previous topic :: View next topic » 
Author Message
LH33
PostPosted: Mon Jan 26, 2004 7:53 am    Post subject: Is a Route To Message Flow Multi-threaded? Reply with quote

Master

Joined: 21 Nov 2002
Posts: 200

I have a message flow that has 5 Route To Labels. If two messages show up on the input queue at almost exactly the same time (difference in milliseconds), are they multi threaded through the flow or does the flow wait until the first message read makes it completely through the flow before reading the next message?

I have a situation where this happened and the second message that was on the input queue was completed before the first. The amount of processing in the Compute node of the RouteTo of the second message is smaller than the processing for the second message. Could this explain it?

Thanks!! Lisa
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Mon Jan 26, 2004 8:59 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

It depends on how many "Additional Instances" you have set up for the message flow.

If you have none, then WMQI should run each message flow as a single thread within the execution group, picking up each message in queue order and processing it fully before getting the next message.

At least, as far as I know.

If you have at least one additional instance deployed, then you will see parallel processing occur. Each instance of the message flow will pull the next available message as they finish. So you could have seen two messages pulled simultaneously, one to each thread, and the faster thread will finish first.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
LH33
PostPosted: Mon Jan 26, 2004 9:03 am    Post subject: Reply with quote

Master

Joined: 21 Nov 2002
Posts: 200

I only have one instance of the flow running, so what you are saying is that it should process a message to completion before reading the next message?

Thanks, Lisa
Back to top
View user's profile Send private message
EddieA
PostPosted: Mon Jan 26, 2004 10:19 am    Post subject: Reply with quote

Jedi

Joined: 28 Jun 2001
Posts: 2453
Location: Los Angeles

Perhaps Jeff should have explained a little more. There are 2 ways you might have 'additional instances' running.

Firstly, you can deploy the Flow to multiple Execution Groups. Each of these EGs will be a different process.

Also, for each Flow within an EG, you can define Additional Instances. These will be different threads within the process.

And of course, you can use both techniques together.

If you have neither set, then yes, each message will be processed completely before the next is read from the queue.

How do you know that the messages got 'reversed' during the flow.

Cheers,
_________________
Eddie Atherton
IBM Certified Solution Developer - WebSphere Message Broker V6.1
IBM Certified Solution Developer - WebSphere Message Broker V7.0
Back to top
View user's profile Send private message
LH33
PostPosted: Mon Jan 26, 2004 10:28 am    Post subject: Reply with quote

Master

Joined: 21 Nov 2002
Posts: 200

Thanks!! I do not have the flow deployed to Multiple Execution Groups nor do I have multiple instances running.

The system that writes messages to the input queue, writes a log of each message with a timestamp. The log shows that the messages were written in the right order to the input queue.

The system that processes the messges from the output queue processed the second message first. (There are also logs from that system that showed this.)

Thanks, Lisa
Back to top
View user's profile Send private message
kirani
PostPosted: Mon Jan 26, 2004 10:46 am    Post subject: Reply with quote

Jedi Knight

Joined: 05 Sep 2001
Posts: 3779
Location: Torrance, CA, USA

Lisa,

What was the message priority in MQMD header for these two messages? By-default Message Delivery Sequence on the queue's is set to Priority, this means highest priority messages will be picked up by the message flow (application) first for processing.
Are you changing/setting priority in your message flow?
Do you have other sub-flows within your message flow, which updates the message, like an Error handler, or common routine.
_________________
Kiran


IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries

Back to top
View user's profile Send private message Visit poster's website
jefflowrey
PostPosted: Mon Jan 26, 2004 10:53 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

This is something I haven't been very clear on myself, so I'm wondering out loud, rather than saying that this has happened or could have happened.

When message roll-back occurs, due to a recoverable error, could the flow then pick up the next message, process it, and then process the first message again?

I haven't ever bothered to do experiments to show what happens during rollback when there are other messages on the queue, and it's been a while since I read that section of the documentation.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
LH33
PostPosted: Mon Jan 26, 2004 11:14 am    Post subject: Reply with quote

Master

Joined: 21 Nov 2002
Posts: 200

I'm trying to see if I can get the Message priority for the two messages, however they have already been processed and I have to try to re-create the situation and capture the Message before it is processed.

I do not change the priority in the Message Flow and the Error routine I have just adds some additional tags to the message before writing it to an error queue if it is in error. In this case, neither transaction resulted in an error.

Thanks!! Lisa
Back to top
View user's profile Send private message
kirani
PostPosted: Mon Jan 26, 2004 11:38 am    Post subject: Reply with quote

Jedi Knight

Joined: 05 Sep 2001
Posts: 3779
Location: Torrance, CA, USA

JeffLowrey wrote:

When message roll-back occurs, due to a recoverable error, could the flow then pick up the next message, process it, and then process the first message again?

Message flow will not pick-up the next message for processing without completing the current UOW.

In this case, Lisa is writing the failed messages to "Error" queue, which will complete the current UOW. So, the message flow will never pick-up that message once again for processing.
_________________
Kiran


IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries

Back to top
View user's profile Send private message Visit poster's website
LH33
PostPosted: Mon Jan 26, 2004 12:02 pm    Post subject: Reply with quote

Master

Joined: 21 Nov 2002
Posts: 200

According to the author of the interface which puts the messages on my input queue, he does not set the priority. He says it is the default priority of: MQPRI_PRIORITY_AS_Q_DEF

Thanks, Lisa
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 » Is a Route To Message Flow Multi-threaded?
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.