flowable/flowable-engine · error · FlowableIllegalArgumentException
Unsupported variable query operation: " + friendlyName
Error message
Unsupported variable query operation: " + friendlyName
What it means
QueryVariable.QueryVariableOperation.forFriendlyName resolves a query operation string (e.g. equals, notEquals, like, greaterThan) used in variable query requests to an enum constant. When the supplied friendly name matches none of the enum's friendlyName values, FlowableIllegalArgumentException is thrown.
Solutions
- Use one of the documented operation names exactly (e.g. equals, notEquals, like, greaterThan, greaterThanOrEquals, lessThan, lessThanOrEquals).
- Log the accepted values by inspecting QueryVariableOperation.values() and their friendlyName fields for your Flowable version.
- Fix client code or query builder to emit the friendly name, not symbolic operators.
- Check for Activiti-to-Flowable migration differences in query operation naming.
Example fix
// before
{"name":"priority","operation":">","value":50}
// after
{"name":"priority","operation":"greaterThan","value":50} Defensive patterns
Strategy: validation
Validate before calling
if (operation == null || !List.of("equals","notEquals","like","greaterThan","greaterThanOrEquals","lessThan","lessThanOrEquals").contains(operation)) {
throw new IllegalArgumentException("Bad operation " + operation);
} Try / catch
try { query = QueryVariableOperation.forFriendlyName(op); } catch (FlowableIllegalArgumentException e) { /* use a documented friendly name */ } Prevention
- Use enum-friendly names, never symbolic operators
- Check QueryVariableOperation values for your Flowable version
- Watch for Activiti migration renaming operations
When it happens
Trigger: Building a variable query (task/process variable filtering via REST) with an "operation" field that is not one of the enum's defined friendly names, e.g. "eq", ">", "contains", or a misspelled value.
Common situations: Clients ported from Activiti/older Flowable using different operation names, hand-written JSON query bodies with wrong operation strings, or auto-generated clients using operator symbols instead of the friendly names.
Understand the failure class
Background: Invalid enum value errors: "Unknown type", "Invalid scope", "must be one of" — when a string is not on the library's allowed list — this error's family across 23 libraries.
Related errors
- Invalid variable scope: '" + scope + "'
- Unsupported variable query operation:
- Unsupported variable query operation:
- Unsupported variable query operation
- Unsupported variable query operation: " +…
AI-assisted analysis of flowable/flowable-engine@d6d39ce1c6 (2026-09-11).
Data as JSON: /api/errors/892e7759fef4fcb4.
Report an issue: GitHub.
Appendix: source
Thrown at modules/flowable-rest/src/main/java/org/flowable/rest/service/api/engine/variable/QueryVariable.java:94
"greaterThanOrEquals"), LESS_THAN("lessThan"), LESS_THAN_OR_EQUALS("lessThanOrEquals"), EXISTS("exists"), NOT_EXISTS("notExists");
private String friendlyName;
private QueryVariableOperation(String friendlyName) {
this.friendlyName = friendlyName;
}
public String getFriendlyName() {
return friendlyName;
}
public static QueryVariableOperation forFriendlyName(String friendlyName) {
for (QueryVariableOperation type : values()) {
if (type.friendlyName.equals(friendlyName)) {
return type;
}
}
throw new FlowableIllegalArgumentException("Unsupported variable query operation: " + friendlyName);
}
}
}
View on GitHub (pinned to d6d39ce1c6)