Embedded Case Management with CMMN in camunda BPM

  • Blog
  • >
  • Embedded Case Management with CMMN in camunda BPM

30 Day Free Trial

Bring together legacy systems, RPA bots, microservices and more with Camunda Platform 8

Join the Camunda Developer Newsletter

Get the latest events, release notes, and product updates straight to your mailbox.

In our latest alpha release we include a preview of the upcoming support for CMMN (Case Management Model and Notation) in camunda BPM. Time to have a look at CMMN and the way it is implemented in camunda BPM.


What is CMMN?

CMMN is an emerging OMG standard for (Adaptive) Case Management. Version 1.0 is freshly released and vendor adoption starts to take off. Trisotech already provides a Web-based Modeler for CMMN and we at camunda have the ambition to provide the first embedded, Open Source Runtime Engine for CMMN.

CMMN allows modeling Cases. A case allows humans to do work in a more or less structured way in order to achieve something. Classic examples where case management is applied are Credit Application, Customer Support Management, Document Management, and so on.

The following is a simple Example of a Credit Application Case modeled in CMMN:

Example of a Credit Application Case modeled in CMMN

The Picture above shows the graphical representation of the CMMN Model. The model also has an executable XML representation which looks like this:
<?xml version="1.0" encoding="ISO-8859-1" standalone="yes"?>

<definitions id="_81291489-586f-4b00-b7c4-1ef8f7523c29"

  <case id="loanApplication" name="Loan Application Case">

    <casePlanModel name="Loan Application" id="CasePlanModel_1">

      <planItem definitionRef="Stage_1" id="PI_Stage_1"/>
      <planItem definitionRef="HumanTask_6" id="PI_HumanTask_6"/>

      <humanTask name="Capture Applicant Data" id="HumanTask_1"/>
      <humanTask name="Obtain Schufa-Information" id="HumanTask_2"/>
      <humanTask name="Obtain Credit-worthiness" id="HumanTask_3"/>
      <humanTask name="Review Documents" id="HumanTask_4"/>
      <humanTask name="Request Missing Documents" id="HumanTask_5"/>
      <humanTask name="Decide About Loan Application" id="HumanTask_6"/>

      <stage name="Obtain Customer Data" id="Stage_1">
        <planItem definitionRef="HumanTask_1" id="PI_HumanTask_1"/>
        <planItem definitionRef="HumanTask_2" id="PI_HumanTask_2"/>
        <planItem definitionRef="HumanTask_3" id="PI_HumanTask_3"/>
        <planItem definitionRef="HumanTask_4" id="PI_HumanTask_4"/>
        <planItem definitionRef="HumanTask_5" id="PI_HumanTask_5"/>



New Features in 7.2.0-alpha3

In camunda BPM 7.2.0-alpha3 we implemented the basic Case Instance and Plan Item Instance lifecycle. On top of this, the following task types are available:

  • Stage
  • Human Task
  • Process Task
  • Case Task

Using API you can now start and complete cases and perform the lifecycle on the plan items:

  // deploy the case definition

    // create a new case instance
    CaseInstance caseInstance = caseService
      .setVariable("applicantId", "some id ...")
    // as a result, the stage and the tasks are enabled.

    // Query for the stage execution
    CaseExecution stageExecution = caseService.createCaseExecutionQuery()

    // start the stage

    // now the "Review Documents" task is enabled:
    CaseExecution reviewDocumentsExecution = caseService.createCaseExecutionQuery()

    // start the review documents task:

    // complete the review documents task:
      .setVariable("allDocumentsObtained", true)

    // ...

Read the Docs

There is some documentation on the CMMN implementation available.

We have published a getting started guide for CMMN.

Try All Features of Camunda Platform

Related Content

Get all the latest updates and recaps of what's happening in this live blog of CamundaCon 2023.
Get all the latest updates and recaps of what's happening in this live blog of CamundaCon 2023.
Learn how Connectors from a process orchestration solution like Camunda can pair with RPA tools to make automation easier.