flowable/flowable-engine · error · FlowableIllegalArgumentException

The variable value does not contain an operator value

Error message

The variable value does not contain an operator value

What it means

Each entry in the 'variableValues' array of the serialized query must declare an 'operator' field that maps to a QueryOperator. When the operator field is absent or null, populateQueryVariableValues throws this FlowableIllegalArgumentException because the comparison semantics of the variable filter are undefined.

Source

Thrown at modules/flowable-engine/src/main/java/org/flowable/engine/impl/delete/BatchDeleteProcessConfig.java:346

    protected static void populateOrQueryObjects(JsonNode orQueryObjectsNode, HistoricProcessInstanceQuery query,
            ProcessEngineConfigurationImpl engineConfiguration) {
        if (orQueryObjectsNode.isArray()) {
            for (JsonNode orQueryObjectNode : orQueryObjectsNode) {
                HistoricProcessInstanceQuery orQuery = query.or();
                populateQuery(orQueryObjectNode, orQuery, engineConfiguration);
                query.endOr();
            }
        }
    }

    protected static void populateQueryVariableValues(JsonNode variableValuesNode, HistoricProcessInstanceQuery query,
            ProcessEngineConfigurationImpl engineConfiguration) {
        if (variableValuesNode.isArray()) {
            for (JsonNode variableValue : variableValuesNode) {
                String operatorString = variableValue.path("operator").stringValue(null);
                if (operatorString == null) {
                    throw new FlowableIllegalArgumentException("The variable value does not contain an operator value");
                }

                QueryOperator operator = QueryOperator.valueOf(operatorString);
                String variableName = variableValue.path("name").stringValue(null);
                switch (operator) {
                    case EQUALS:
                        if (variableName != null) {
                            query.variableValueEquals(variableName, extractVariableValue(variableValue, engineConfiguration));
                        } else {
                            query.variableValueEquals(extractVariableValue(variableValue, engineConfiguration));
                        }
                        break;
                    case NOT_EQUALS:
                        query.variableValueNotEquals(variableName, extractVariableValue(variableValue, engineConfiguration));
                        break;
                    case GREATER_THAN:
                        query.variableValueGreaterThan(variableName, extractVariableValue(variableValue, engineConfiguration));
                        break;

View on GitHub (pinned to d6d39ce1c6)

Solutions

  1. Add the required 'operator' field to each variable value object (e.g. "operator": "EQUALS")
  2. Validate the batch configuration JSON before creating the batch part
  3. Consult QueryOperator for the exact allowed operator names

Example fix

// before
{ "name": "status", "value": "DONE" }
// after
{ "name": "status", "operator": "EQUALS", "value": "DONE" }
Defensive patterns

Strategy: validation

Validate before calling

for (JsonNode var : variableValuesJson) {
    if (var.path("operator").stringValue(null) == null) {
        throw new IllegalArgumentException("variableValue missing operator: " + var);
    }
}

Try / catch

try {
    config = BatchDeleteProcessConfig.create(partId, engineConfiguration);
} catch (FlowableIllegalArgumentException e) {
    logger.error("Invalid variable filter: " + e.getMessage());
}

Prevention

When it happens

Trigger: Batch delete configuration JSON where a variableValue object in the array lacks the 'operator' key, e.g. { "name": "status", "value": "DONE" }.

Common situations: Hand-crafted batch configurations; tooling that omits the operator assuming a default; schema drift after copying query JSON from another format.

Understand the failure class

Background: "missing required argument" and "the following required arguments were not provided": what required-argument errors mean and how to fix them — 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/6c045bd38bdcf845. Report an issue: GitHub.