This is the third article in a five-part series on how to use Rational's latest best-practices development process guidance and modeling tools to design and construct robust, flexible IT solutions based on service-oriented architectures. Rational SOMA 2.9 provides detailed best practices development process guidance for successful IT service solution design. Rational Software Architect provides industry-leading modeling tools that support the new SoaML services modeling standard from the Object Management Group.
In the first article we introduced Rational Software Architect, version 7.5.4 and higher, and Rational SOMA 2.9 as a unified tool set and process guidance offering for accelerating service solution design and development results. The second article provided an overview of the process guidance content and features of Rational SOMA 2.9 in particular.
This third article describes how Rational Software Architect can be used to construct business process models using Business Process Modeling Notation (BPMN). First, we will briefly discuss what business process modeling is all about, who typically does it (and why), and how it fits into the process. Then we’ll give an overview of the various modeling elements of BPMN that are supported by Rational Software Architect. Finally, we will show you how to use the business process modeling tools to build a small business process model.
Fundamentally, business process modeling is a way to describe and document how a business, or part of a business, operates (or wishes to operate). A business process model captures the steps or tasks that must be performed (including decision points), the entities or roles that are to perform them (e.g., people, IT systems), and how they interact to process and share information (data).
Business process modeling is done for a variety of purposes and at many levels of abstraction and detail. Here are a few examples.
- A company's business leaders might want to capture their current business processes as input into analyzing how they could be more efficient. This would probably involve creating modified business process models to describe their ideas about how to do so and might also include simulating the performance of the as-is and to-be processes, using a tool such as WebSphere Business Modeler.
- New or existing business process models can be used to provide business-oriented inputs to service identification, as was described in the second article.
- An IT development organization might create executable business processes for deployment onto, say, WebSphere Process Server.
This article focuses on the use illustrated by the second example. We view business process models as a way for the business to communicate requirements to IT in the context of SOA and business-driven development.
Rational Software Architect includes the ability to create and edit business process models that are based on the BPMN 2.0 standard from the Object Management Group. This support was added in Rational Software Architect 7.5.4 and has been enhanced in subsequent releases. That it is well integrated with the service modeling tools also included in Rational Software Architect is no accident.
In this section we'll give you a brief overview of BPMN. But first, we will create a new BPMN model in Rational Software Architect because it will give us something to look at and will provide a context in which the pieces are easier to understand. It also helps provide an introduction to the BPMN editor and tooling.
The first step in business process modeling in Rational Software Architect is to create a business process model in a project. Assuming that we do not already have a suitable project, we will create one and a new business process model within it using the Model Project wizard. If you are not already in the Modeling perspective you should open it at this point by selecting "Open Perspective > Other..." from the "Window" menu. Then invoke the Model Project wizard by selecting "New > Model Project" from the "File" menu.
In the Model Project wizard (see Figure 1) enter a name for your new project, ensure that the other settings are as shown, and press "Next".
Figure 1. Model Project wizard
On the "Create Model" page (see Figure 2), select the "Business Process Modeling" category and then the "Blank Process Model" template.
Note: If the "Business Process Modeling" category is not listed, try selecting the "Show All Templates" checkbox just beneath the "Categories" list. If it is still not listed then you probably do not have the Business Process Modeling feature of Rational Software Architect installed, in which case you’ll need to install it before proceeding.
Figure 2. The Create Model page of the Model Project wizard
Give your new model a good name (like "MyProcess") and click "Finish". You should end up in the BPMN editor opened on your new business process model in your new project. Your process model will be empty to start with. Your workbench should look something like Figure 3.
Figure 3. Workbench with new business process model
Let's take a quick look at each relevant section of the workbench that you might not be familiar with if you're new to business process modeling.
The big empty space in the middle is our new (empty) business process model opened in the business process model editor. That's where we will be focusing much of our attention as we build our business process model.
Just below that is the Properties view (see Figure 4). As usual, the format and content it shows is specific to whatever is selected in the currently active view or editor. Since the business process model editor is active, but with nothing selected, the Properties view shows the properties of the process being edited. There are more properties than could be shown at once so there are tabs along the left that let you select whatever category of properties you are interested in.
Figure 4. The Properties view
Along the right-hand side of the editor is the Palette (see Figure 5, in which we've expanded the Task drawer so that you can see the full set of available items). The items in the palette are the "building blocks" with which we can build our process model.
Figure 5. The business process modeling palette
We will not be using all of these elements in the example we will build in this article, so here is a brief description of each. This will also give you a brief overview of the kinds of things you can describe using BPMN.
- A Text Annotation is used to add a box of explanatory text to a process model diagram. It has no underlying semantic meaning. Think of it as comments or documentation (although there are other ways to include documentation as well).
- A Group is simply a way to draw a boundary around other elements in a business process model. It is merely diagrammatic, and has no underlying semantic meaning.
- Connector is used to draw connections of various types between other business process model elements. The type of connection it creates depends on the source and target that you select. For example, if you use the Connector tool to create a connection from one task to another, it will create a Sequence Flow connection, because that is the only valid type of connection that one can make between tasks.
- A Data Object is used to represent a unit of data used by a process. It is transient in the sense that it exists only during the running of the process.
- A Data Store is used to represent a persistent store of data (a database, for example). While it is running, a process may retrieve and/or store data objects from or to a data store, respectively.
- A Lane represents a grouping of activities, usually to indicate that they are all performed by the same entity (e.g., person or IT system) or role.
- A Task represents an "atomic" unit of work or activity in a process, one that cannot be (or has been chosen not to be) further subdivided. The palette offers four kinds of Tasks.
- Task itself represents a generic activity, consisting of just its name and (optionally) documentation.
- A User Task represents an activity that is to be performed by a person (but often presumably done by the person invoking a software application of some kind). One can set its implementation type to be WebServiceHumanTask, WebService, Other or Unspecified.
- A Business Rule Task represents an activity that is to be performed by a business rules engine of some kind. One can set its implementation type to be WebServiceBusinessRuleTask, WebService, Other or Unspecified.
- A Service Task represents an activity that uses a service. One can set its implementation type to be WebService, Other or Unspecified. One can also set its operation, which can be a BPMN operation of an interface in a business process model or a UML operation of an interface in a UML model. Typically, the latter will be an operation of a SoaML «ServiceInterface».
- A Call Activity represents an activity that will call a Global Task (explained later) or another Process to do its job. This gives us the ability to reuse these tasks and processes in many contexts.
- Events represent non-local flow of execution (i.e., that which does not follow a Sequence Flow connection). There are five kinds.
- A Start Event and End Event are used to indicate the beginning or end of a process, respectively.
- An Intermediate Throw Event indicates that execution is to continue at a corresponding Intermediate Catch Event.
- A Boundary Event is attached to an activity to indicate abnormal execution of some kind (i.e., something has happened such that the normal sequence flow from the activity does not occur).
- A Gateway element represents a point in a process at which the local flow of process execution can change. A gateway element can have multiple incoming and outgoing sequence flows.
- An Exclusive Gateway represents a decision point from which exactly one of its outgoing Sequence Flows will occur. A single condition will be evaluated in order to determine which one.
- An Inclusive Gateway is like an Exclusive Gateway except that more than one of its outgoing Sequence Flows may occur (resulting in parallel execution). Each outgoing Sequence Flow has a condition that will be evaluated to determine whether or not it occurs. One of them can be set as the default Sequence Flow which will occur if all of the conditions evaluate as false.
- A Parallel Gateway unconditionally results in the execution of all of its outgoing sequence flows. That is, it always initiates parallel execution (unless it has just a single outgoing sequence flow, of course). A Parallel Gateway acts the same as an Inclusive Gateway for which all of its outgoing Sequence Flows' conditions evaluate unconditionally as true.
That covers what the Palette provides. The Project Explorer shows a few additional element type possibilities that it would also be useful and instructive to go through briefly. If you fully expand it you’ll see something like Figure 6.
Figure 6. MyProcess in the Project Explorer
Each of the items under MyProcess represents a category of additional resources that you can add to your process model (except for the last one, which represents the Process itself). Each one provides a context menu that allows you to create a new element of its type. As with the palette, we will not be using all of these resource types in the example we build in this article, but here is a brief description of each one in order to help you better understand BPMN. I will go through them in a different order than they are listed in the Project Explorer in order to minimize having to refer to ones I haven’t described yet.
- Global Tasks – A Global Task represent an atomic (un-subdivided) unit of work. Unlike the Tasks referred to above that you can add directly to a process, Global Tasks are reusable in that they can be called from any number of processes (via Call Activities).
- Data Stores – We described Data Stores above where we noted that you can add them to your Process from the palette in the business process model editor. Any that you created that way would show up here (as will any that you create here, too, of course). This means that Data Stores are reusable and can be referenced from this or other processes.
- Item Definitions – An Item Definition represents a data structure or data type. BPMN does not itself provide a way to define what the structure of the data is to be, however. Instead, it relies on other standards and mechanisms for that. Rational Software Architect allows you to use an XSD type or a UML class to define the structure of an Item Definition.
- Messages – A Message represents information that will be sent between two entities in a process (or between two processes). A Message contains a reference to an Item Definition to specify its payload.
- Escalations – An Escalation represents non-local flow of control and is typically thrown by a Process to indicate that it has encountered something that prevents it from completing normally. Typically, the caller or parent of the Process would be responsible for catching an Escalation and handling it. An Escalation can reference an Item Definition that can be used to pass information from the thrower to the catcher. Within a Process you can associate an Event with an Escalation to indicate what it throws or catches.
- Signals – A Signal is similar to an Escalation in that it represents non-local flow of control, can reference an Item Definition, and can be referenced by an Event within a Process. Unlike an Exception, a Signal is typically expected to be thrown during normal Process execution and does not necessarily indicate that a problem or something unexpected has been encountered.
- Interfaces – An Interface exists to contain Operations that can be referenced by Service Tasks. After you create an Interface, you can select it and add Operations to it. For each Operation you can specify an input Message and, optionally, an output Message that together define what data the Operation requires and produces.
Let's say we want to model our company's order processing process. To start with, we determine that the Order Processing department works with three other departments. The Finance department handles invoicing, the Production department handles production scheduling and product manufacturing, and the Shipping department handles shipping orders to customers. We decide to represent each of these departments as a Lane in our process in order to clearly indicate who does what.
To create our first Lane, we click on the Lane element in the palette and then click within the business process model editor to indicate where we want our new Lane to be placed. Where we click doesn’t really matter much at this point because we can rearrange things as we go along. If we name our first Lane "Order Processing" we will have something like Figure 7.
Figure 7. The Order Processing Lane
We add the other Lanes, too, as is shown in Figure 8.
Figure 8. Four Lanes
Next we will add a Start Event to show where our process begins. As we did with the Lanes, we click on the Start Event in the palette and then click in our Process at the location we want it placed. In this case, we will put it in the Order Processing Lane near the left-hand side. We will name the event "Order Received" because that’s what happens to kick the whole process off.
We want to represent that we really receive something that we care about and process: an order. It is useful and appropriate to model this as a Message whose reception triggers the Start Event. So we select our Start Event and then click on the Triggers tab in the Properties view (see Figure 9).
Figure 9. The Triggers Tab
To add a Message event trigger we click on the small blue envelope. (If we'd wanted to create a different kind of trigger, we'd have clicked on the down arrow next to the envelope to reveal additional choices.) We do not really care what the name of the event definition is so we’ll leave it with the default name. We do want to specify a Message for it, however, so we click on the plus sign to the right of the Message field. See Figure 10.
Figure 10. The Triggers tab of the Properties view showing which buttons to press
This creates a new Message for us, which we will name "Order Message". We also want to specify that it contains an actual order, so we click on the plus sign next to the Structure field. This creates a new Item Definition for us, which we’ll name "Order". These new elements appear in the Properties view as well as in our Process model in the Project Explorer (see Figure 11 and Figure 12).
Figure 11. Properties view showing new elements
Figure 12. Project Explorer showing new elements
Once an order has been received, the Order Processing department needs to do three things:
- Request Production to manufacture the ordered product
- Notify Shipping about the pending product shipment
- Have Invoicing do initial pricing calculations for the order
These three tasks can be done at the same time, so we add a Parallel Gateway to our Process. We also add a Task to each of the other three Lanes to indicate what they need to do. See Figure 13.
Figure 13. After adding Parallel Gateway and Tasks
Then we draw the Sequence Flows to show the intended flow of execution so far. A handy way to draw a Sequence Flow between two elements is to put the mouse pointer over the source element (the Order Received Start Event, for example) and, when the connector handles appear, move the mouse pointer to the outgoing one, press and hold mouse button 1, move to the desired target element, and release the mouse button. See Figure 14.
Figure 14. Drawing a sequence flow
We also draw Sequence Flows from the Parallel Gateway to each of the three Tasks we added above. See Figure 15.
Figure 15. After drawing three more sequence flows
Then we add the remaining elements we need to complete our Process model example (Figure 16).
Figure 16. Completed process
Obviously, this is a rather trivial process model. Real world business processes are typically much more complex than this. But it serve well as an example with which we can show how to do service analysis and modeling in the next article.
In this article we described the Rational Software Architect tools for building business process models using Business Process Modeling Notation (BPMN). First, we briefly explained what business process modeling is all about, who typically does it (and why), and how it fits into the overall process. We then gave a brief overview of the BPMN modeling elements that are supported by Rational Software Architect. Finally, we showed you how to use the business process modeling tools to build a small business process model.
The remaining articles in this series provide details regarding the creation of service models and solutions that effectively meet the requirements expressed by the business process model:
- Article 4 describes the service design tooling in Rational Software Architect and how this can be used to build business-aligned service models; and
- Article 5 describes how service models built using Rational Software Architect can be used to accelerate the creation of valuable service solution artifacts. Specifically, this article focuses on leveraging service models to create SCA-related content.
- BPMN (Business Process Modeling Notation) is a standard from the Object Management Group that specifies a notation for describing business processes.
- SoaML (Service Oriented Architecture Modeling Language) is a specification of the Object Management Group. SoaML defines a notation and a meta-model for describing and specifying service-oriented systems.
- Watch the two-part video series Business Process Modeling and SOA Design with Rational Software Architect 8.0 .
- Learn more about SOA and service
governance in Bobby Woolf's developerWorks article, Introduction to SOA governance.
- To learn more about IBM Global Business
Service's proprietary method for service design and development, read SOMA: A method for developing service-oriented solutions.
- IBM now delivers its commercial best practices content in the form of largely-separable, discretely-adoptable practices. Visit Welcome to IBM practices on
developerWorks to learn more about our Practices.
- One of the major sources of inspiration
for the detailed service design method in Rational SOMA is the IBM Redbook, "Building SOA Solutions Using the
Rational SDP". The latest update to the Redbook occurred in 2008,
thus the tooling it illustrates is dated. Nonetheless, this is a good
service design resource to have on your "book shelf".
- Rational SOMA 2.9 borrows much of its
approach to service modeling using SoaML from Jim Amsden's 5-part IBM
developerWorks series, "Modeling with SoaML, the Service-Oriented Architecture Modeling Language".
- Visit the OASIS Service Component Architecture (SCA) site to learn more about these open-industry specifications for creating service components using a wide range of implementation and run-time technologies.
Get products and technologies
Rational SOMA 2.9. This is
IBM's commercially-available best practices content for service solution design. The URL points to a pre-published evaluation version of Rational SOMA 2.9 and to a full version, which can be published using Rational Method Composer. Rational SOMA also is productized as a Process Advisor configuration that ships with variants of Rational Software Architect, Version 8.0 and higher, that include the service modeling tooling.
- Download a
trial version of Rational Software Architect for WebSphere Software. If you have a choice of versions, we recommend Version 8.0 or higher. To experience the enhanced service solution design capabilities of Rational Software Architect, you will need to use Version 7.5.4 or greater. If you download Version 7.5, then use IBM Installation Manager – which is installed along with Rational Software Architect – to upgrade to the current version of the product that is in the 7.5.x code stream.
Gary Johnston is a Senior Software Engineer and SOA Tools Architect in the Rational Software Architect development organization. For the past couple of years, Gary has been working to deliver and enhance support for SOA design and development in Rational Software Architect itself and to better integrate it with other SOA-related tools (both Rational and non-Rational).
Todd Dunnavant is a Principal Solution Architect in the Solution Delivery Assurance team of IBM’s Rational brand. He also is the primary author of the Rational SOMA best practices for service solution design. For the past 14 years, his professional passion has been enabling Rational and IBM clients to improve their ability to deliver business-relevant software and system solutions. His current focal areas of interest are service-oriented systems and collaborative architecture management.