Author |
Message
|
er_pankajgupta84 |
Posted: Fri Oct 19, 2012 8:43 am Post subject: Design consideration - Web services vs MDB |
|
|
 Master
Joined: 14 Nov 2008 Posts: 203 Location: charlotte,NC, USA
|
Just wanted some thoughts on these 2 design considerations:
I have a scenario where I have to call 4-5 different services (hosted in WAS) sequentially from broker.
Here are my 2 design consideration:
1. Use Soap/Http and call all services as web service on WAS
MQInput -> Compute Node1 -> SoapRequest1-> Compute Node2 -> SoapRequest2-> Compute Node3 -> SoapRequest3 -> Compute Node4 -> MQOutput
In this design I would be storing my original message in the Environment and using it/ enriching it after each web service call to create message for other web service request.
2. Use XML/MQ and call all services as MDB on WAS
MQInput -> Compute Node1 -> MQOutput1->MQGet1-> Compute Node2 -> MQOutput2->MQGet2-> Compute Node3 -> MQOutput3->MQGet3-> Compute Node4 -> MQOutput
In this design I would be storing my original message in the Environment and using it/ enriching it after each MQGet to create message for other web service request.
I will be doing some sort of POC and compare both this approaches.
I just need some general suggestion which could be a better approach. Leave the Non- functional requirement, my focus is better response time, better thruput & optimal resource utilization. |
|
Back to top |
|
 |
lancelotlinc |
Posted: Fri Oct 19, 2012 9:46 am Post subject: |
|
|
 Jedi Knight
Joined: 22 Mar 2010 Posts: 4941 Location: Bloomington, IL USA
|
Both approaches will work. WS is more immediate. Either way, use subflows. Put each SOAP interaction in its own subflow.
Subflow: Input -> FlowOrder Leg 1 -> Trace -> Compute -> Trace -> SoapRequest or MQ -> Trace -> Compute -> End of Leg 1 // FO Leg 2 -> Output
This way, you don't need to store original message in the Environment, you just store the net result of each call in the Environment. You keep the original message propagating down the line for each subflow. _________________ http://leanpub.com/IIB_Tips_and_Tricks
Save $20: Coupon Code: MQSERIES_READER |
|
Back to top |
|
 |
er_pankajgupta84 |
Posted: Fri Oct 19, 2012 12:44 pm Post subject: |
|
|
 Master
Joined: 14 Nov 2008 Posts: 203 Location: charlotte,NC, USA
|
Suggestion accepted. There could be more improvement to how I am going to orchestrate the flow.
But the real questions stays as is.. Would it be advisable to take WS route using SOAPRequest nodes or MDB route using Mqoutput & MQGet nodes. |
|
Back to top |
|
 |
mqjeff |
Posted: Fri Oct 19, 2012 1:53 pm Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
To complicate matters, consider SOAP/JMS. |
|
Back to top |
|
 |
Esa |
Posted: Fri Oct 19, 2012 1:57 pm Post subject: Re: Design consideration - Web services vs MDB |
|
|
 Grand Master
Joined: 22 May 2008 Posts: 1387 Location: Finland
|
er_pankajgupta84 wrote: |
MQInput -> Compute Node1 -> SoapRequest1-> Compute Node2 -> SoapRequest2-> Compute Node3 -> SoapRequest3 -> Compute Node4 -> MQOutput
In this design I would be storing my original message in the Environment and using it/ enriching it after each web service call to create message for other web service request.
...
I just need some general suggestion which could be a better approach. Leave the Non- functional requirement, my focus is better response time, better thruput & optimal resource utilization. |
Dear er, I don't know who - in the dawn of times - came up with the idea of calling a message broker flow a flow, but I think it is a misleading term and you don't have to let it distract your thinking. If you understand how the propagation model works, and I guess you do, you understand that an MB flow does not have to be a straight sequence of nodes, because - unlike the ordinary, more moist flows - it is capable of moving things upstream (Yes, Vitor, I know trouts move upstream - good point!).
So, the best performing solution - regardless of the transport - would be a "spider" compute or java compute node propagating to several terminals/labels and collecting data via LocalEnvironment. That way you don't have to store anything in Environment and the memory usage of the flow will be the lowest possible (if you know what you are doing).
If you are propagating to 4-5 SOAPRequests, this will work "out of the box", but if you are propagating tens or hundreds of times, you must understand how to avoid orphaning parsers - but that's another story.
Last edited by Esa on Fri Oct 19, 2012 9:42 pm; edited 2 times in total |
|
Back to top |
|
 |
fjb_saper |
Posted: Fri Oct 19, 2012 3:59 pm Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
MDB or SOAP/JMS may give you a definitive advantage if you can't use HTTP v 1.1 and keep alive connection...  _________________ MQ & Broker admin |
|
Back to top |
|
 |
er_pankajgupta84 |
Posted: Tue Oct 23, 2012 5:52 am Post subject: |
|
|
 Master
Joined: 14 Nov 2008 Posts: 203 Location: charlotte,NC, USA
|
If I go with MDB implemented in WAS then I am seeing a strange behaviour on load balancing.
Here is what IBM says on this:
"Each MDB configured to listen on a queue will use a single input handle to browse messages. Once a message has been detected it will be passed to a server session to process (destructively get). This server session will create a new input handle (if it doesn't already have one) to destructively get the message. There is no guarantee that MDB occurrences will get equal number of messages, or indeed if all of them will actually be started. However if there are enough messages on the queue, and the MDBs do meaningful work you would typically see most of them being active at some point. The same thing applies to MDBs in a cluster, one server might end up processing more than the other one. Reducing the value of maximum server sessions might cause work to be shared more evenly but doesn't guarantee it. "
Anyone has experience with MDB managing high loads .. need some suggestion on best practices using MDBs, ideal size of session pool for each MDB etc. |
|
Back to top |
|
 |
wbi_telecom |
Posted: Tue Oct 23, 2012 11:24 am Post subject: |
|
|
 Disciple
Joined: 15 Feb 2006 Posts: 188 Location: Harrisburg, PA
|
We used the following presentation to fine tune our MDBs.
WA1359 WebSphere v6 Performance Tuning
I am not sure how much messages you are expecting to process but we process 100-125 messages per second second per server in our MDBs.
Cheers, |
|
Back to top |
|
 |
er_pankajgupta84 |
Posted: Tue Oct 23, 2012 11:58 am Post subject: |
|
|
 Master
Joined: 14 Nov 2008 Posts: 203 Location: charlotte,NC, USA
|
|
Back to top |
|
 |
|