Comments
Richard Davies wrote: The UK has a good crop of technology pioneers in cloud computing - for example ElasticHosts, FlexiScale, Flexiant, OnApp - and also some strong government initiatives such as G-Cloud. We will have to see whether this kind of technical leadership converts into swift mass-market adoption or not.
Cloud Expo on Google News

SYS-CON.TV
Cloud Expo & Virtualization 2009 East
PLATINUM SPONSORS:
IBM
Smarter Business Solutions Through Dynamic Infrastructure
IBM
Smarter Insights: How the CIO Becomes a Hero Again
Microsoft
Windows Azure
GOLD SPONSORS:
Appsense
Why VDI?
CA
Maximizing the Business Value of Virtualization in Enterprise and Cloud Computing Environments
ExactTarget
Messaging in the Cloud - Email, SMS and Voice
Freedom OSS
Stairway to the Cloud
Sun
Sun's Incubation Platform: Helping Startups Serve the Enterprise
POWER PANELS:
Cloud Computing & Enterprise IT: Cost & Operational Benefits
How and Why is a Flexible IT Infrastructure the Key To the Future?
Click For 2008 West
Event Webcasts
BPEL in a Service-Oriented Architecture
BPEL's benefits for SOA

Service-oriented architectures (SOA) have gained much attention recently as a unifying technical architecture that can be concretely embodied with Web service technologies. SOA is a design model deeply rooted in the concept of encapsulating application logic within services that interact via a common communications framework. A key aspect of the Web service incarnation of SOA is that the Web service is viewed as a fundamental building block of an SOA-based application.

BPEL, originally called BPEL4WS (Business Process Execution Language for Web Services) is a language for describing Web service orchestration in terms of stateful, long-running interactions consisting of synchronous and asynchronous message exchanges. It supplies a notion of abstract processes to describe externally visible behavior as well as executable processes, which can be run either by some interpreter or by compiling them into some executable form. This article focuses on executable BPEL processes and presents one view on the benefits that BPEL brings to an XML Web service embodiment of SOA principles. BPEL plays an important role in SOA by providing a powerful means by which business logic can be articulated and executed at an abstraction level designed to provide the services needed for integration tasks.

Example: Travel Services
In order to illustrate what problems BPEL addresses and how it relates to SOA, we'll consider an example from the travel industry. Imagine a company offering travel services over the Web. The operations might include:

  • getAvailableHotels: Takes an input of an airport code and returns a list of hotels near that airport.
  • getDescription: Takes an input of a hotel identifier and returns a description.
  • getRate: Takes as input a hotel identifier, the type and number of rooms, and the date and provides a quote for the rate.
  • makeReservations: Takes as input the hotel identifiers, dates to reserve, and room information. Makes the reservation and returns the confirmation number.
  • cancelReservation: Takes a confirmation number and cancels the reservation.
When making a hotel reservation, all of these operations may be called in the process of making a reservation. The messages utilized by these services may be based on vertical industry definitions, such as those provided by the OpenTravel Alliance (OTA; www.opentravel.org). For example, the travel company may write its own WSDLs that rely heavily on the OTA schemas. For simplicity, we will assume that each operation is modeled as a separate service.

Let's consider what happens when we want to create a reusable service that represents some common scenario, such as shopping for a hotel. We will be calling several services, some of which will need to be invoked serially. For example, we need to get the list of hotels near a given airport in order to request detailed descriptions and rates for the hotels. Other services can be invoked in parallel, e.g., once we have the list of hotels, we may want to request descriptions and rates for all of them at once instead of one at a time. Some pieces may require user interaction, such as reviewing the list of options and deciding for which hotel to make the reservation.

We can envision this process as a flowchart consisting of basic activities and structural activities. Examples of basic activities include receiving messages, invoking external services, and assigning values from one message to another. Structural activities may include a sequence that performs nested activities in sequence, and a flow that performs nested activities in parallel. It turns out that this notion of activities is exactly what BPEL provides. In BPEL, the aforementioned activities are receive, invoke, assign, sequence, and flow. Fifteen such activities are defined in BPEL along with non-activity elements such as processes, partner links, variables, and correlations.

Listing 1 shows a brief snippet of how activities might be used in hotel shopping. Details such as data manipulation are omitted for clarity. The point to gain from this is that activities are represented as elements, and subactivities are represented as child elements. Therefore, the structure of XML reflects the structure of the process in an obvious way.

Structured collections of activities such as this can be used to define BPEL processes, which are in turn exposed as Web services; of course, this could also be done in a traditional programming language. So far, the primary benefit we have seen in BPEL is that the notion of interacting with Web services is built into the language. If our focus is almost exclusively on Web service orchestration, it is in some sense more natural to use a language that has these concepts built into it rather than a more general-purpose programming language. Nevertheless, this by itself is not very compelling because there are plenty of libraries that simplify the task of sending and receiving messages with protocols such as SOAP. We will expose more compelling reasons for preferring BPEL in this scenario as we go along.

A WSDL-Centric View of Web Services
Implementing our travel services in a Web service–based SOA implies a decomposition into Web services. A naive implementation of this idea would force the use of SOAP to communicate between all reusable parts of the application, gaining modularity at the expense of efficiency. However, we need not make this trade-off if we are careful about the ontological commitments we make about the notion of a Web service.

The defining technical characteristic of a service from a BPEL standpoint is that it is described in a WSDL. Every message exchange is described in a BPEL process in terms of portTypes and operations defined in the WSDL. BPEL does not assume that services are accessed via SOAP over HTTP, so when appropriate, more efficient bindings may be used. For example, the Apache Web Service Invocation Framework (WSIF) defines WSDL extensions for bindings of local Java invocations, EJBs, JMS, and Java Connection Architecture connectors.

Binding information is not accessed directly in BPEL, but is controlled through deployment configurations. This means that our hotel shopping process can be written in a way that is binding-agnostic, cleanly separating the business logic from lower-level concerns.

Message Exchange Patterns and Stateful Services
Our hotel shopping scenario requires input from the user twice: once to initiate the request with criteria for the city or airport and the dates, and once more to review the offerings and either pick a hotel or cancel the request. Because this input happens twice, the whole service cannot directly be modeled as a simple request/response pair. We have a number of options for how to model this:

  1. The process provides three request/ response operations: getDescriptions AndRates(), makeReservation(), and cancel().
  2. The process exposes a one-way operation to initiate the hotel from shopping. The customer provides a request/response for picking the hotel from the list of choices or canceling.
  3. Each message is modeled as a one-way operation.
About Jim Clune
Jim Clune is a development manager for Parasoft, where he has worked on a number of automated error prevention solutions. His experience with Web services includes the development of testing tools and his most recent project, which is a BPEL runtime engine. Jim holds a BS in engineering from Harvey Mudd College and is working towards a PhD in computer science at the University of California, Los Angeles.

In order to post a comment you need to be registered and logged in.

Register | Sign-in

Reader Feedback: Page 1 of 1

Service-oriented architectures (SOA) have gained much attention recently as a unifying technical architecture that can be concretely embodied with Web service technologies. SOA is a design model deeply rooted in the concept of encapsulating application logic within services that interact via a common communications framework. A key aspect of the Web service incarnation of SOA is that the Web service is viewed as a fundamental building block of an SOA-based application.

Service-oriented architectures (SOA) have gained much attention recently as a unifying technical architecture that can be concretely embodied with Web service technologies. SOA is a design model deeply rooted in the concept of encapsulating application logic within services that interact via a common communications framework. A key aspect of the Web service incarnation of SOA is that the Web service is viewed as a fundamental building block of an SOA-based application.

Thanks, very good article !
I just want to emphasize, in the area where you explain 'Transaction Life', that a result of introducing Compensation handlers, must be (by nature) that these are NOT long-running activities themselves. Fault handling within Compensation handlers, must also be treated with care, otherwise one can end up writing an entire 2-Phase commit protocol.

Thanks for the inspiration I got sofar, though.


Your Feedback
SOA Web Services Journal News Desk wrote: Service-oriented architectures (SOA) have gained much attention recently as a unifying technical architecture that can be concretely embodied with Web service technologies. SOA is a design model deeply rooted in the concept of encapsulating application logic within services that interact via a common communications framework. A key aspect of the Web service incarnation of SOA is that the Web service is viewed as a fundamental building block of an SOA-based application.
SOA Web Services Journal News Desk wrote: Service-oriented architectures (SOA) have gained much attention recently as a unifying technical architecture that can be concretely embodied with Web service technologies. SOA is a design model deeply rooted in the concept of encapsulating application logic within services that interact via a common communications framework. A key aspect of the Web service incarnation of SOA is that the Web service is viewed as a fundamental building block of an SOA-based application.
Peter Rosenberg wrote: Thanks, very good article ! I just want to emphasize, in the area where you explain 'Transaction Life', that a result of introducing Compensation handlers, must be (by nature) that these are NOT long-running activities themselves. Fault handling within Compensation handlers, must also be treated with care, otherwise one can end up writing an entire 2-Phase commit protocol. Thanks for the inspiration I got sofar, though.
Latest Cloud Developer Stories
Many times over the last year I have been asked the question, "What is Windows Intune?" I like to describe Windows Intune as the cloud service helps you centrally manage and secure your PCs through a simple, web-based console. Released back in March 2011, Windows Intune has alre...
Why are APIs so important in clouds? Do APIs have to be open? How fast or slow will standardization in the cloud be? Why is ensuring high availability for the cloud service critical? In his session at the 10th International Cloud Expo, Mårten Mickos, CEO of Eucalyptus Systems, w...
Very few trends in IT have generated as much buzz as cloud computing. In his session at the 10th International Cloud Expo, Mark Hinkle, Director, Cloud Computing Community at Citrix, will cut through the hype and quickly clarify the ontology for cloud computing. The bulk of the c...
The proliferation of device connectivity is redefining the functionality requirements and capabilities of many embedded systems as more and more of these devices look to leverage the “Cloud.” While many commercial software and hardware component vendors have begun to realign thei...
Hardware and chemistry improvements will make the $1,000 human genome a reality soon. While the massive amount of genomics data that will be generated represents a huge opportunity to advance personal medicine, it also presents an enormous big data challenge. In his session at ...
Subscribe to the World's Most Powerful Newsletters
Subscribe to Our Rss Feeds & Get Your SYS-CON News Live!
Click to Add our RSS Feeds to the Service of Your Choice:
Google Reader or Homepage Add to My Yahoo! Subscribe with Bloglines Subscribe in NewsGator Online
myFeedster Add to My AOL Subscribe in Rojo Add 'Hugg' to Newsburst from CNET News.com Kinja Digest View Additional SYS-CON Feeds
Publish Your Article! Please send it to editorial(at)sys-con.com!

Advertise on this site! Contact advertising(at)sys-con.com! 201 802-3021

SYS-CON Featured Whitepapers
ADS BY GOOGLE

Breaking Cloud Computing News

Alvarion Ltd. (NASDAQ:ALVR) a provider of optimized wireless broadband solut...