{"record":{"id":"5f902bbf35a41418","repo":"flowable/flowable-engine","slug":"deployment-ids-is-null-5f902b","errorCode":null,"errorMessage":"Deployment ids is null","messagePattern":"Deployment ids is null","errorType":"validation","errorClass":"FlowableIllegalArgumentException","httpStatus":null,"severity":"error","filePath":"modules/flowable-engine/src/main/java/org/flowable/engine/impl/DeploymentQueryImpl.java","lineNumber":78,"sourceCode":"    }\n\n    public DeploymentQueryImpl(CommandExecutor commandExecutor) {\n        super(commandExecutor);\n    }\n\n    @Override\n    public DeploymentQueryImpl deploymentId(String deploymentId) {\n        if (deploymentId == null) {\n            throw new FlowableIllegalArgumentException(\"Deployment id is null\");\n        }\n        this.deploymentId = deploymentId;\n        return this;\n    }\n\n    @Override\n    public DeploymentQueryImpl deploymentIds(List<String> deploymentIds) {\n        if (deploymentIds == null) {\n            throw new FlowableIllegalArgumentException(\"Deployment ids is null\");\n        }\n        this.deploymentIds = deploymentIds;\n        return this;\n    }\n\n    @Override\n    public DeploymentQueryImpl deploymentName(String deploymentName) {\n        if (deploymentName == null) {\n            throw new FlowableIllegalArgumentException(\"deploymentName is null\");\n        }\n        this.name = deploymentName;\n        return this;\n    }\n\n    @Override\n    public DeploymentQueryImpl deploymentNameLike(String nameLike) {\n        if (nameLike == null) {\n            throw new FlowableIllegalArgumentException(\"deploymentNameLike is null\");","sourceCodeStart":60,"sourceCodeEnd":96,"githubUrl":"https://github.com/flowable/flowable-engine/blob/d6d39ce1c69ff244f2d9dc6af756a9b95e865586/modules/flowable-engine/src/main/java/org/flowable/engine/impl/DeploymentQueryImpl.java#L60-L96","documentation":"DeploymentQueryImpl.deploymentIds(List<String>) throws FlowableIllegalArgumentException when the list itself is null. Flowable rejects a null collection at builder time; note that an empty list is accepted here, so only a true null triggers the error. The list supplies an IN-clause of deployment ids.","triggerScenarios":"repositoryService.createDeploymentQuery().deploymentIds(null), typically when the id list is built dynamically and a null slips through (uninitialized collection, null return from a lookup).","commonSituations":"Bulk filters fed by another service call that returned null instead of an empty list; deserialized request bodies where the ids array was absent.","solutions":["Pass a non-null List, e.g. Collections.emptyList() if there are no ids.","Normalize inputs: query.deploymentIds(ids == null ? Collections.emptyList() : ids).","Skip the filter call entirely when no ids are provided."],"exampleFix":"// before\nquery.deploymentIds(deploymentIds); // NPE-ish when list is null\n// after\nif (deploymentIds != null && !deploymentIds.isEmpty()) {\n    query.deploymentIds(deploymentIds);\n}","handlingStrategy":"validation","validationCode":"List<String> ids = (rawIds == null) ? Collections.emptyList() : rawIds;\nif (!ids.isEmpty()) {\n    query.deploymentIds(ids);\n}","typeGuard":"boolean isNonNullIdList(List<String> ids) { return ids != null; }","tryCatchPattern":"try {\n    query.deploymentIds(deploymentIds);\n} catch (FlowableIllegalArgumentException e) {\n    log.warn(\"Null deployment id list\", e);\n}","preventionTips":["Initialize id collections to empty lists rather than leaving them null","Normalize nullable collections at API boundaries","Remember Flowable checks the list reference, not its contents"],"tags":["flowable","query-builder","null-argument","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"}