Welcome to BARMAGY Sign in | Join | Help

Services composition…

is one of the wide narrated terminologies around the industry these times; I am here merely attempting to explain it

                It’s a process by which you create a service that utilizes existing services to provide new functionality, either by directly aggregating results or adding to results some logic that extends the functionality of the existing services.

 

                Elements:  (SERVICE, is a web service, normally I refrain from using it this way but just for clarity)

-          Service A : provide a certain functionality, response time is 0.5 X

-          Service B: provide a certain functionality, response time is 0.5 X

-          Challenge:

o   Provide a functionality that basically based on the 2 services (some calc might be needed)

o   (to add some excitement) Provide response time under 1.0 X

 

To do that we need to create a new service which basically calls the 2 services harvest the response do the calc and then return. Interestingly enough there are so many ways to do that

-          WCF service that directly calls into each services in sequential way collect the results and return

o   Will not be able to provide under 1.0 X

-          WCF services that spawn off a couple of threads to do that (or method invoker) and collect result , this will include a bit of code and really takes a lot to maintain and change

-          BizTalk orchestrations exposed as a WCF service, that does the same thing

o   Will not be able to provide under 1.0 X, as BTS persistence will eat up the time

-          Possible Solution:

o   Use a WCF service that runs a workflow that executes the 2 calls in a parallel fashion aggregate them, no persistence or anything just pure code.  In this model we are not using any host/WF instance communication which adds a lot of performance benfits.

 how it looks like

 

 

Today I was into a discussion where the approach was proposed to fulfill a fairly straight forward requirements, putting things in place really shows the benefits of service orientation. Code here to download

-          Service A Lib, Class library for service A

-          Service A Host, console application hosting Service A

-          Service B Lib, Class Library for service B

-          Service B Host, Console application hosting service B

-          Composethis, our composite service  (console application)

o   1 * workflow that calls service A & service B

o   1 * service that calls into the workflow

o   Hosting and configuration

-          Composethisclient, a client that calls composethis service (console)

All included in one solution and using basicHttpBinding for clarity

 

Enjoy

Kal

ServiceComposeServiceCompose
Published Wednesday, November 07, 2007 7:51 AM by KAL
Attachment(s): ServiceCompose.zip

Comment Notification

If you would like to receive an email when updates are made to this post, please register here

Subscribe to this post's comments using RSS

Comments

# re: Services composition…

Thursday, April 24, 2008 9:09 AM by DarkMan

# re: Services composition…

eA5hE3  <a href="http://ifswfnzlykea.com/">ifswfnzlykea</a>, [url=http://mspfioyvglbn.com/]mspfioyvglbn[/url], [link=http://nfigfnwtnnkg.com/]nfigfnwtnnkg[/link], http://gtilcqfoufwp.com/
Thursday, April 24, 2008 7:53 PM by skietagktnr

# re: Services composition…

g7FT5E  <a href="http://fxxnfiawyidj.com/">fxxnfiawyidj</a>, [url=http://kocdjpewvlch.com/]kocdjpewvlch[/url], [link=http://hgaxvourikyh.com/]hgaxvourikyh[/link], http://rlgxtsvzanrw.com/
Friday, April 25, 2008 6:32 AM by yicsquldegn

What do you think?

(required) 
required 
(required)