Posts

Showing posts with the label Camunda Production Issue

Camunda BPMN Gateway Condition – Best Practices

Camunda BPMN Gateway Condition – Best Practices (Production-Safe Guide) Gateway conditions in Camunda BPMN control how a process flows at runtime. Yet, incorrect gateway conditions are one of the top reasons for production incidents in Camunda projects. In this blog, we’ll cover best practices for writing gateway conditions , common mistakes, and how to avoid runtime failures in Camunda 7 (and Camunda 8 concepts apply too). 1️⃣ Why Gateway Conditions Break Production A gateway condition: Is evaluated at runtime Must always return a Boolean Is executed inside the process engine context A small mistake can lead to: Process instance stuck Incident in Cockpit Production outage 2️⃣ Always Return Boolean (MOST IMPORTANT RULE) ❌ Wrong condition (very common): ${orderStatus} If orderStatus = "APPROVED" , Camunda throws: condition expression returns non-Boolean ✅ Correct condition: ${orderStatus == 'APPROVED' } 👉 Gateway conditions ...

Camunda 7 External Task Retry Not Working – Fix

Camunda 7 External Task Retry Not Working – Root Cause & Fix (Production Guide) External Tasks are widely used in Camunda 7 to decouple business logic from the process engine. However, a very common production issue teams face is: ❌ External Task retries are not working as expected. In this blog, we’ll cover why retries fail , real root causes , and how to fix them safely in production . 1️⃣ How External Task Retry Works in Camunda 7 In Camunda 7, retries are controlled by: retries count lockDuration lockExpirationTime Failure handling logic in the worker A retry happens only when the worker explicitly reports failure . 2️⃣ Most Common Reasons Retries Don’t Work ❌ 1. handleFailure() Not Called Correctly Wrong implementation (very common): try { // business logic } catch (Exception e) { throw e; // ❌ This does NOT trigger retry } Correct implementation: externalTaskService.handleFailure( externalTask, "Processing failed...

Camunda DMN Boolean Error in Production – Root Cause and Fix

 One of the most common Camunda DMN issues seen in production environments is the infamous Boolean evaluation error , where a decision table fails with a message indicating that a condition did not return a Boolean value . This problem often: Does not appear in development Surfaces suddenly after deployment Blocks process execution in production In this blog, we’ll cover: The exact root causes of this issue Why it appears unexpectedly in production Proven fixes used in real projects đź”´ Typical Error Message You may see an error similar to: Cannot evaluate expression: condition expression returns non - Boolean : result has class java.lang.String and not java.lang.Boolean or FEEL expression did not return a Boolean result This usually occurs when: A process reaches a DMN decision task A decision table condition is evaluated Camunda expects true or false , but receives something else đź§  Root Cause Analysis (Most Important Section) ...