Sunday, July 3, 2011

Service Oriented Architecture (SOA) - Thought #4 : Orchestration and Choreography

For quite long time, I have heard of people talking about service orchestration and service choreography. Once, during a job interview, I was asked to explain the difference between the two. It seems to me there are confusions between these two terms.

So let’s take a step back to the basics of their definitions. I am copying/pasting the definition from dictionary.com:

Orchestration: (1) to compose or arrange (music) for performance by an orchestra.  (2) to arrange or manipulate, especially by means of clever or thorough planning or maneuvering: to orchestrate a profitable trade agreement.

Choreography: (1) the art of composing ballets and other dances and planning and arranging the movements, steps, and patterns of dancers.  (2) the arrangement or manipulation of actions leading up to an event: the choreography of a surprise birthday party.

Even with the help of dictionary, the real difference between them is quite subtle. My interpretation of the difference is that orchestration is to have a group of participants perform a common activity such as symphony from beginning to end; while choreography is to arrange pieces together to make a thing happen (an event).

Back to the technical world, orchestration is used frequently now to describe assembling, in the SOA arena, services (either atomic or composite) into a business process. This business process can work with other business processes to enable & enhance business capabilities. This is a kind of orchestration. Specifically, the business process service can be controlled and coordinated by a controller service (like a conductor with a symphony if you will). On the other side, choreography is more for peer-to-peer collaborations, such as business to business (B2B) services. It would be interesting to know when and how the term of choreography started to be used as a technical term. One guess from me is the W3C specs of Web Services Choreography Description Language back to year 2004. According to this specs, the web services choreography “is targeted for composing interoperable, peer-to-peer collaborations between any type of Web Service participant regardless of the supporting platform or programming model used by the implementation of the hosting environment”.

Side note: In just one sentence, peer-to-peer referrers to collaboration of servers as oppose to client-to-server .

No comments:

Post a Comment