flowable/flowable-engine · warning

property not found in task name expression

Error message

property not found in task name expression {}

What it means

Logged by UserTaskActivityBehavior when evaluating the task's name expression throws an ActivitiException (e.g. property/variable referenced by the expression does not exist). The raw expression text is used as the task name as fallback and the flow continues.

Solutions

  1. Ensure the variable/property referenced by the name expression exists before the task is created
  2. Add defaulting to the expression, e.g. ${order.customerName ?: 'unknown'}
  3. Correct typos in the expression in the BPMN XML

Example fix

// before
<userTask name="Approve ${order.customerName}" />
// after
<userTask name="Approve ${order.customerName != null ? order.customerName : 'unknown'}" />
Defensive patterns

Strategy: validation

Validate before calling

Object n = execution.getVariable("order");
if (n == null) throw new BpmnError("MISSING_VAR", "order not set before approval task");

Try / catch

try { name = (String) expr.getValue(execution); } catch (ActivitiException e) { name = expr.getExpressionText(); LOGGER.warn(...); }

Prevention

When it happens

Trigger: A user task with a name expression like ${order.customerName} where the property is missing or expression evaluation fails at runtime.

Common situations: Renamed/removed process variables referenced in task name expressions; typos in EL property paths; missing variable initialization before the user task.

Understand the failure class

Background: 'Could not be found', 'does not exist', 'not found in database': the resource-not-found family when an ID, slug, key, or URI lookup comes back empty — this error's family across 20 libraries.

Related errors


AI-assisted analysis of flowable/flowable-engine@d6d39ce1c6 (2026-09-11). Data as JSON: /api/errors/8a12e919d8b53900. Report an issue: GitHub.

Appendix: source

Thrown at modules/flowable5-engine/src/main/java/org/activiti/engine/impl/bpmn/behavior/UserTaskActivityBehavior.java:136

            activeCandidateGroupExpressions = taskDefinition.getCandidateGroupIdExpressions();
        }

        Expression skipExpression = taskDefinition.getSkipExpression();
        boolean skipUserTask = SkipExpressionUtil.isSkipExpressionEnabled(activityExecution, skipExpression) &&
                SkipExpressionUtil.shouldSkipFlowElement(activityExecution, skipExpression);

        TaskEntity task = TaskEntity.createAndInsert(activityExecution, !skipUserTask);
        task.setExecution(execution);

        task.setTaskDefinition(taskDefinition);

        if (activeNameExpression != null) {
            String name = null;
            try {
                name = (String) activeNameExpression.getValue(execution);
            } catch (ActivitiException e) {
                name = activeNameExpression.getExpressionText();
                LOGGER.warn("property not found in task name expression {}", e.getMessage());
            }
            task.setName(name);
        }

        if (activeDescriptionExpression != null) {
            String description = null;
            try {
                description = (String) activeDescriptionExpression.getValue(execution);
            } catch (ActivitiException e) {
                description = activeDescriptionExpression.getExpressionText();
                LOGGER.warn("property not found in task description expression {}", e.getMessage());
            }
            task.setDescription(description);
        }

        if (activeDueDateExpression != null) {
            Object dueDate = activeDueDateExpression.getValue(execution);
            if (dueDate != null) {

View on GitHub (pinned to d6d39ce1c6)