{"record":{"id":"ba7899e714bda77c","repo":"flowable/flowable-engine","slug":"process-definition-name-is-null","errorCode":null,"errorMessage":"Process definition name is null","messagePattern":"Process definition name is null","errorType":"validation","errorClass":"FlowableIllegalArgumentException","httpStatus":null,"severity":"error","filePath":"modules/flowable-engine/src/main/java/org/flowable/engine/impl/ExecutionQueryImpl.java","lineNumber":234,"sourceCode":"    }\n    \n    @Override\n    public ExecutionQuery processDefinitionCategoryLikeIgnoreCase(String processDefinitionCategoryLikeIgnoreCase) {\n        if (processDefinitionCategoryLikeIgnoreCase == null) {\n            throw new FlowableIllegalArgumentException(\"Process definition category is null\");\n        }\n        if (inOrStatement) {\n            this.currentOrQueryObject.processDefinitionCategoryLikeIgnoreCase = processDefinitionCategoryLikeIgnoreCase;\n        } else {\n            this.processDefinitionCategoryLikeIgnoreCase = processDefinitionCategoryLikeIgnoreCase;\n        }\n        return this;\n    }\n\n    @Override\n    public ExecutionQuery processDefinitionName(String processDefinitionName) {\n        if (processDefinitionName == null) {\n            throw new FlowableIllegalArgumentException(\"Process definition name is null\");\n        }\n        if (inOrStatement) {\n            this.currentOrQueryObject.processDefinitionName = processDefinitionName;\n        } else {\n            this.processDefinitionName = processDefinitionName;\n        }\n        return this;\n    }\n    \n    @Override\n    public ExecutionQuery processDefinitionNameLike(String processDefinitionNameLike) {\n        if (processDefinitionNameLike == null) {\n            throw new FlowableIllegalArgumentException(\"Process definition name is null\");\n        }\n        if (inOrStatement) {\n            this.currentOrQueryObject.processDefinitionNameLike = processDefinitionNameLike;\n        } else {\n            this.processDefinitionNameLike = processDefinitionNameLike;","sourceCodeStart":216,"sourceCodeEnd":252,"githubUrl":"https://github.com/flowable/flowable-engine/blob/d6d39ce1c69ff244f2d9dc6af756a9b95e865586/modules/flowable-engine/src/main/java/org/flowable/engine/impl/ExecutionQueryImpl.java#L216-L252","documentation":"FlowableIllegalArgumentException thrown by ExecutionQueryImpl.processDefinitionName when the name argument is null. Flowable requires query filters to be omitted rather than set to null, so it throws immediately during query building. This prevents invalid criteria from reaching the SQL layer.","triggerScenarios":"Calling runtimeService.createExecutionQuery().processDefinitionName(null), or in an or-statement setting a null name on currentOrQueryObject.","commonSituations":"Process name pulled from deployment metadata or user selection that is missing; bean properties that default to null.","solutions":["Apply the filter only if the name is non-null.","Default the name at the source (config, DTO, or service layer).","Use processDefinitionNameLike for partial matching.","Omit the name filter to match all definitions."],"exampleFix":"// before\nquery.processDefinitionName(request.getName());\n\n// after\nif (request.getName() != null) {\n    query.processDefinitionName(request.getName());\n}","handlingStrategy":"validation","validationCode":"if (name != null) { query.processDefinitionName(name); }","typeGuard":"boolean hasName = name != null && !name.isEmpty();","tryCatchPattern":"try {\n    query.processDefinitionName(name);\n} catch (FlowableIllegalArgumentException e) {\n    log.warn(\"Null process definition name filter skipped\");\n}","preventionTips":["Never pass optional name values straight from DTOs into the query.","Provide defaults for name fields in configuration.","Wrap Flowable query construction in a builder that filters out nulls."],"tags":["flowable","query","null-argument","process-definition"],"backgroundTag":"null-argument","analyzedSha":"d6d39ce1c69ff244f2d9dc6af756a9b95e865586","analyzedAt":"2026-09-11T06:41:19.413Z","contentChangedAt":"2026-09-11T06:41:19.413Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}