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 » Threading w.r.t HTTPRequest Node

Post new topic  Reply to topic
 Threading w.r.t HTTPRequest Node « View previous topic :: View next topic » 
Author Message
gakd1987
PostPosted: Wed Jan 06, 2016 10:31 am    Post subject: Threading w.r.t HTTPRequest Node Reply with quote

Apprentice

Joined: 20 Aug 2013
Posts: 26

I have a situation and I need to make sure my thinking goes right.

We have a restful broker flow and we are running 100 instances of this flow in a execution group. There is a layer in the flow where it makes a httpRequest call to the datapower to get a response.

1. First of all I want to make sure that httpRequest node Synchronous . Am I right about this? and thats the reason we have http Asynchronous node provided to us ?

2. If it is synchronous will the behaviour be something like as explained below ?
If we have 50 instances of the flow running and if one of the instances takes 20 secs to get back the response using http Request node then will the rest of 49 requests will wait till it gets chance to use http request node ? or is it that the 50 instacnes of the flow will have 50 instances of httpreuquest which are synchronized as well to run parallely?
Back to top
View user's profile Send private message
Vitor
PostPosted: Wed Jan 06, 2016 11:00 am    Post subject: Re: Threading w.r.t HTTPRequest Node Reply with quote

Grand High Poobah

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

gakd1987 wrote:
1. First of all I want to make sure that httpRequest node Synchronous . Am I right about this? and thats the reason we have http Asynchronous node provided to us ?


Yes

gakd1987 wrote:
2. If it is synchronous will the behaviour be something like as explained below ?
If we have 50 instances of the flow running and if one of the instances takes 20 secs to get back the response using http Request node then will the rest of 49 requests will wait till it gets chance to use http request node ? or is it that the 50 instacnes of the flow will have 50 instances of httpreuquest which are synchronized as well to run parallely?


The flow "compiles" the nodes into a series of runtime instructions. So each instance of the flow (50 in the example quoted) will make it's own call rather than single threading through a single "http requester".

Note that if all 50 threads are sitting and waiting for 20 seconds to get a response, any new calls to the flow (i.e. a 51st request) will sit and wait at the input node until an instance becomes available. You should scale appropriately.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Wed Jan 06, 2016 11:09 am    Post subject: Reply with quote

Grand High Poobah

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

Well it all depends on how your response part operates.
If there is a single thread servicing all calls, it matters little that you have 50 calls in parallel if they are only being answered serially....

Like Vitor said, you need to scale appropriately...
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
mqjeff
PostPosted: Wed Jan 06, 2016 11:10 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

You should also really make a lot of performance measurements before you even think about using 50 instances of any flow.

There's almost no chance that you will hit all 50 HTTPRequest nodes at the same time, or even receive 50 input messages at the same time, so there's very little chance of all 50 of those instances being started.

But if they ever do start, you may find that they put an unnecessary burden on the rest of the flows on the machine.

Start with 5. Do testing.
_________________
chmod -R ugo-wx /
Back to top
View user's profile Send private message
Vitor
PostPosted: Wed Jan 06, 2016 11:13 am    Post subject: Reply with quote

Grand High Poobah

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

fjb_saper wrote:
Well it all depends on how your response part operates.
If there is a single thread servicing all calls, it matters little that you have 50 calls in parallel if they are only being answered serially....


This is a good point. It's not going to matter if you've got 50 separate and distinct requests coming out of IIB if DataPower responds one at a time.
_________________
Honesty is the best policy.
Insanity is the best defence.
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 » Threading w.r.t HTTPRequest Node
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.