Tuesday, October 26, 2010

Towards Case Management

Case management was one of the recurring themes last week at the Business Process Forum. There definitely seems to be a growing need amongst end users for more flexible and adaptive business processes, without ending up with overly complex solutions. Everyone seems to agree that using a process-centric approach only in many cases leads to complex solutions that are hard to maintain. The "knowledge workers" no longer want to be locked into rigid processes but wants to have the power and flexibility to regain more control over the process themselves.

The term case management is often used in that context. I'm not going to try and give a precise definition of what it might or might not mean [1,2], but it refers to the basic idea that many applications in the real world cannot really be described completely from start to finish (including all possible paths, deviations, exceptions, etc.). Case management takes a different approach: instead of trying to model what should happen from start to finish, let's give the end user the flexibility to decide what should happen at runtime. In its most extreme form for example, case management doesn't even require any process definition at all. Whenever a new case comes in, the end user can decide what to do next based on all the case data.

A typical example can be found in healthcare (clinical decision support to be more precise), where care plans can be used to describe how patients should be treated in specific circumstances, but people like general practitioners still need to have the flexibility to add additional steps and deviate from the proposed plan, as each case is unique. And there are similar examples in claim management, helpdesk support, etc.

So, should we just throw away our BPM system then? I don't think so! Even at its most extreme form (where we don't model any process up front), you still need a lot of the other features a BPM system (usually) provides: there still is a clear need for audit logs, monitoring, coordinating various services, human interaction (e.g. using task forms), analysis, etc. And, more importantly, many cases are somewhere in between, or might even evolve from case management to more structured business process over time (when we for example try to extract common approaches from many cases). If we can offer flexibility as part of our processes, can't we let the users decide how and where they would like to apply it?

Let me give you two examples that show how you can add more and more flexibility to your processes. The first example shows a care plan that shows the tasks that should be performed when a patient has high blood pressure. While a large part of the process is still well-structured, the general practitioner can decide himself which tasks should be performed as part of the sub-process. And he also has the ability to add new tasks during that period, tasks that were not defined as part of the process, or repeat tasks multiple times, etc. The process uses an ad-hoc sub-process to model this kind of flexibility, possibly augmented with rules or event processing to help in deciding which fragments to execute.


The second example actually goes a lot further than that. In this example, an internet provider could define how cases about internet connectivity problems will be handled by the internet provider. There are a number of actions the case worker can select from, but those are simply small process fragments. The case worker is responsible for selecting what to do next and can even add new tasks dynamically. As you can see, there is not process from start to finish anymore, but the user is responsible for selecting which process fragments to execute.

And in its most extreme form, we even allow you to create case instances without a process definition, where what needs to be performed is selected purely at runtime. This however doesn't mean you can't figure out anymore what 's actually happening. For example, meetings can be very adhoc and dynamic, but we usually want a log of what was actually discussed. The following screenshot shows how our regular audit view can still be used in this case, and the end user could then for example get a lot more info about what actually happened by looking at the data associated with each of those steps. And maybe, over time, we can even automate part of that by using a semi-structured process.

We hope that already goes a long way in supporting your cases!

Monday, October 18, 2010

jBPM5 and BPMN 2.0

jBPM5 introduces a new language for representing process definitions based on the BPMN 2.0 specification, replacing older (proprietary) formats like jPDL or RuleFlow. Because not everyone might be familiar with this specification, let me give you some background. [The BPMN 2.0 specification has been finalized for some time now, but still needs to go through the final steps of the administrative process. Nevertheless, the contents of the specification seems to be stable and ready to be used.]

What is BPMN 2.0?
"The primary goal of BPMN is to provide a notation that is readily understandable by all business users, from the business analysts that create the initial drafts of the processes, to the technical developers responsible for implementing the technology that will perform those processes, and finally, to the business people who will manage and monitor those processes."
The second version of the Business Process Model and Notation specification (BPMN 2.0) by OMG not only defines a standard on how to graphically represent a business process (like BPMN 1.x), but now also includes execution semantics for the elements defined, and an XML format on how to store (and share) process definitions.

For example, a very simple process that would write out "Hello World" when it is started would look something like this (both visual and using XML):


<definitions ... >
 <process id="com.sample.bpmn.hello" name="Hello World">
   <startevent id="_1" name="StartProcess">
   <sequenceflow sourceref="_1" targetref="_2">
   <scripttask id="_2" name="Hello">
     <script>System.out.println("Hello World");</script>
   </scripttask>
   <sequenceflow sourceref="_2" targetref="_3">
   <endevent id="_3" name="EndProcess">
 </process>
</definitions>

The BPMN2 specification contains an explanation of how to represent executable business processes, both visually and syntactically, by combining a large set of different node types (and related elements). jBPM5 supports most of the "Common Executable" subset of the BPMN2 specification (containing the most common node types and attributes for specifying executable business processes) and already a few more node types. The documentation gives a detailed overview of which elements an attributes exactly.

To get started, the BPMN2 specification obviously serves as the reference, but additional to that, the jbpm-bpmn2 module contains a lot of junit tests for each of the currently supported node types. These test processes can also serve as simple examples: they don't really represent an entire real life business processes but can definitely be used to show how specific features can be used. For example, the following figures shows the flow chart of a few of those examples. The entire list can be found here.


Want to know more details, check out the BPMN2 chapter in the jBPM5 documentation.

Tuesday, October 5, 2010

Here we go ... first jBPM5 snapshots !

We've been talking about it for a while now, and working on it even longer, but we believe the time has come to just get the jBPM5 code out there and start asking for community feedback and assistance.

The current jBPM5 snapshot offers open-source business process execution and management, including
  • an embeddable, light-weight process engine in Java, supporting native BPMN2 execution
  • BPMN2 process modeling, both in Eclipse (developers) and web-based (business users)
  • process collaboration, monitoring and management through the Guvnor repository and the management consoles
  • human interaction using an independent WS-HT human task service
  • strong and powerful integration with business rules and event processing

So where to start looking?

For those that want to get their hands on the source code:
http://github.com/krisv/jbpm

Documentation (which is still under heavy construction but will be extended significantly in the next few weeks) can be found here.

And you can always download the latest snapshot binaries, sources, the gwt-console, documentation and an installer here:
https://hudson.jboss.org/hudson/job/jBPM5/lastSuccessfulBuild/artifact/target

Enjoy !