{"record":{"id":"3a030f9f570282d6","repo":"flowable/flowable-engine","slug":"provided-job-id-list-is-null","errorCode":null,"errorMessage":"Provided job id list is null","messagePattern":"Provided job id list is null","errorType":"validation","errorClass":"FlowableIllegalArgumentException","httpStatus":null,"severity":"error","filePath":"modules/flowable-job-service/src/main/java/org/flowable/job/service/impl/DeadLetterJobQueryImpl.java","lineNumber":112,"sourceCode":"    }\n\n    @Override\n    public DeadLetterJobQueryImpl jobId(String jobId) {\n        if (jobId == null) {\n            throw new FlowableIllegalArgumentException(\"Provided job id is null\");\n        }\n        if (inOrStatement) {\n            this.currentOrQueryObject.id = jobId;\n        } else {\n            this.id = jobId;\n        }\n        return this;\n    }\n\n    @Override\n    public DeadLetterJobQuery jobIds(Collection<String> jobIds) {\n        if (jobIds == null) {\n            throw new FlowableIllegalArgumentException(\"Provided job id list is null\");\n        }\n        if (inOrStatement) {\n            this.currentOrQueryObject.jobIds = jobIds;\n        } else {\n            this.jobIds = jobIds;\n        }\n        return this;\n    }\n\n    @Override\n    public DeadLetterJobQueryImpl processInstanceId(String processInstanceId) {\n        if (processInstanceId == null) {\n            throw new FlowableIllegalArgumentException(\"Provided process instance id is null\");\n        }\n        if (inOrStatement) {\n            this.currentOrQueryObject.processInstanceId = processInstanceId;\n        } else {\n            this.processInstanceId = processInstanceId;","sourceCodeStart":94,"sourceCodeEnd":130,"githubUrl":"https://github.com/flowable/flowable-engine/blob/d6d39ce1c69ff244f2d9dc6af756a9b95e865586/modules/flowable-job-service/src/main/java/org/flowable/job/service/impl/DeadLetterJobQueryImpl.java#L94-L130","documentation":"DeadLetterJobQueryImpl.jobIds(Collection<String>) validates the collection argument; a null list is rejected with FlowableIllegalArgumentException(\"Provided job id list is null\"). Note the method is also invoked internally from execute() when expanding query filters, so a null list stored earlier surfaces at execution time.","triggerScenarios":"Calling jobIds(null) directly; or a null jobIds collection having been set and then consumed by execute() (which calls this method) during query execution.","commonSituations":"Collecting job ids from an upstream call that returned null instead of an empty list; passing an uninitialized collection field; ORM/JSON deserialization producing null for an absent list.","solutions":["Pass an empty collection instead of null if no ids should be filtered","Null-check the collection before calling jobIds()","Fix upstream data sources to return empty collections rather than null","If triggered from execute(), ensure no code path assigns null to the query's jobIds field"],"exampleFix":"// before\nquery.jobIds(idsFromSomewhere); // may be null\n// after\nquery.jobIds(idsFromSomewhere == null ? Collections.emptyList() : idsFromSomewhere);","handlingStrategy":"validation","validationCode":"query.jobIds(jobIds == null ? Collections.emptyList() : jobIds);","typeGuard":"boolean hasJobIds(Collection<String> ids) { return ids != null; }","tryCatchPattern":"try {\n    query.jobIds(jobIds);\n} catch (FlowableIllegalArgumentException e) {\n    query.jobIds(Collections.emptyList());\n}","preventionTips":["Return empty collections, never null, from id-collecting code","Normalize collections at API boundaries before query building","Remember execute() re-invokes jobIds — stored nulls surface at execution time","Add unit tests for queries built with absent filter values"],"tags":["query","null-check","flowable","job-service","collection"],"backgroundTag":"null-argument","analyzedSha":"d6d39ce1c69ff244f2d9dc6af756a9b95e865586","analyzedAt":"2026-09-11T06:41:19.413Z","contentChangedAt":"2026-09-11T06:41:19.413Z","schemaVersion":2},"datasetVersion":"2026-09-18T11:17:12.947Z"}