Case Management in jBPM 7
💡 Introduction
Traditional BPMN processes are structured and predictable, defining every path in advance.
However, real-world business scenarios often need flexibility — such as handling customer complaints, legal cases, or insurance claims — where each case evolves differently.
That’s where Case Management in jBPM 7 comes in.
It enables dynamic, event-driven, and context-aware processes, giving knowledge workers the ability to make decisions during execution — not just at design time.
🧠 1️⃣ What Is Case Management?
Case Management is a knowledge-driven process where the flow isn’t strictly predefined.
It combines human decision-making with automated process fragments, allowing flexibility in execution.
✅ Key difference from BPMN:
| Feature | BPMN Process | Case Management |
|---|---|---|
| Flow Type | Predefined | Dynamic & flexible |
| Control | Process engine | Case worker decisions |
| Adaptability | Low | High |
| Example | Order fulfillment | Customer complaint resolution |
🧩 2️⃣ Core Concepts in jBPM Case Management
| Concept | Description |
|---|---|
| Case File | A shared container holding data (variables) across all tasks |
| Case Definition (.bpmn) | The model defining stages, milestones, tasks, and rules |
| Case Instance | A runtime instance of the case definition |
| Case ID | A unique identifier assigned automatically to each case |
| Milestone | A checkpoint that represents an achieved condition or goal |
| Ad-Hoc Task | A task that can be triggered at any time, not bound by sequence flow |
⚙️ 3️⃣ jBPM Case Management Architecture
🏗️ 4️⃣ Case Project Setup
🧾 1. Create a Case Project
In Business Central → Design → Projects → New → Case Project
Select:
-
Case Definition type
-
Name:
CustomerComplaintCase -
Package:
com.sample.case
⚙️ 2. Case Definition (Case.bpmn)
Your process definition file (example: CustomerComplaintCase.bpmn) will include:
-
Start Event (optional)
-
Ad-hoc Human Tasks (e.g., Review Complaint, Request Documents, Approve Refund)
-
Milestones (e.g., Complaint Registered, Refund Processed)
-
Dynamic sub-processes
-
Case File Variables
🧩 5️⃣ Case File Variables
Case files store data used by all tasks in the case.
Example:
| Variable | Type | Purpose |
|---|---|---|
customerName | String | Customer initiating complaint |
complaintType | String | Type of complaint (billing, delivery, etc.) |
refundAmount | Double | Amount to be refunded |
approvalStatus | String | Approved or Pending |
XML Definition:
🧩 6️⃣ Ad-Hoc Tasks
Ad-hoc tasks can be triggered anytime during case execution.
For example:
| Task | Type | Description |
|---|---|---|
| Review Complaint | Human | Review submitted complaint |
| Request Documents | Human | Ask customer for more info |
| Approve Refund | Human | Approve or reject refund request |
| Close Case | Human | Mark case as completed and close it |
🧱 7️⃣ Milestones in a Case
Milestones represent achievements or checkpoints.
They can be auto-completed based on conditions.
Example:
| Milestone | Condition |
|---|---|
| Complaint Registered | Case variable complaintType not null |
| Refund Approved | approvalStatus == "APPROVED" |
FEEL Expression Example:
🖼️ 8️⃣ Customer Complaint Case Flow Diagram
Below is the visual representation of the Customer Complaint Case with its milestones and ad-hoc tasks —
created in a BPMN-style Case Management diagram using jBPM 7.
📊 It illustrates how tasks like Review Complaint, Request Documents, Approve Refund, and Close Case can be triggered dynamically, with milestones marking progress checkpoints.
🚀 9️⃣ Starting a Case Instance (REST or Java)
Using REST API
Example:
Response:
Using Java API
🔄 🔟 Triggering an Ad-Hoc Task
Once a case is active, you can trigger ad-hoc tasks dynamically using:
Or via Java:
🧠 11️⃣ Case Lifecycle
| State | Description |
|---|---|
| Active | Case running |
| Completed | Case successfully closed |
| Aborted | Case terminated manually |
| Suspended | Case paused temporarily |
🧰 12️⃣ Case Management UI in Business Central
In Business Central, go to:
Menu → Manage → Cases
You can:
-
Start new cases
-
View case status
-
Trigger ad-hoc tasks
-
Add comments and case file items
-
Close or abort cases manually
📊 The UI gives real-time visibility into running case instances.
👉 Watch “Case Management in jBPM 7” in Action:
Here’s a quick demo video showing milestones, case variables, and ad-hoc task triggers in jBPM.
🎬 Coming soon on YouTube: Learn IT with Shikha
🏁 Conclusion
🎯 Case Management in jBPM 7 bridges the gap between structured BPMN automation and flexible, human-driven workflows.
It empowers organizations to handle unpredictable and evolving processes — from customer complaints to HR onboarding — with dynamic control, collaboration, and traceability.
💬 “When every case is different, jBPM Case Management helps you stay organized, compliant, and adaptive.”
💼 Professional Support Available
If you are facing issues in real projects related to enterprise backend development or workflow automation, I provide paid consulting, production debugging, project support, and focused trainings.
Technologies covered include Java, Spring Boot, PL/SQL, Azure, and workflow automation (jBPM, Camunda BPM, RHPAM).
📧 Contact: ishikhanirankari@gmail.com | info@realtechnologiesindia.com
🌐 Website: IT Trainings | Digital metal podium

Comments
Post a Comment