{"record":{"id":"c5c49b47431bd43a","repo":"flowable/flowable-engine","slug":"provided-display-name-is-null","errorCode":null,"errorMessage":"Provided display name is null","messagePattern":"Provided display name is null","errorType":"validation","errorClass":"FlowableIllegalArgumentException","httpStatus":null,"severity":"error","filePath":"modules/flowable-idm-engine/src/main/java/org/flowable/idm/engine/impl/UserQueryImpl.java","lineNumber":168,"sourceCode":"            throw new FlowableIllegalArgumentException(\"Provided full name is null\");\n        }\n        this.fullNameLike = fullNameLike;\n        return this;\n    }\n\n    @Override\n    public UserQuery userFullNameLikeIgnoreCase(String fullNameLikeIgnoreCase) {\n        if (fullNameLikeIgnoreCase == null) {\n            throw new FlowableIllegalArgumentException(\"Provided full name is null\");\n        }\n        this.fullNameLikeIgnoreCase = fullNameLikeIgnoreCase.toLowerCase();\n        return this;\n    }\n    \n    @Override\n    public UserQuery userDisplayName(String displayName) {\n        if (displayName == null) {\n            throw new FlowableIllegalArgumentException(\"Provided display name is null\");\n        }\n        this.displayName = displayName;\n        return this;\n    }\n\n    @Override\n    public UserQuery userDisplayNameLike(String displayNameLike) {\n        if (displayNameLike == null) {\n            throw new FlowableIllegalArgumentException(\"Provided display name is null\");\n        }\n        this.displayNameLike = displayNameLike;\n        return this;\n    }\n\n    @Override\n    public UserQuery userDisplayNameLikeIgnoreCase(String displayNameLikeIgnoreCase) {\n        if (displayNameLikeIgnoreCase == null) {\n            throw new FlowableIllegalArgumentException(\"Provided display name is null\");","sourceCodeStart":150,"sourceCodeEnd":186,"githubUrl":"https://github.com/flowable/flowable-engine/blob/d6d39ce1c69ff244f2d9dc6af756a9b95e865586/modules/flowable-idm-engine/src/main/java/org/flowable/idm/engine/impl/UserQueryImpl.java#L150-L186","documentation":"FlowableIllegalArgumentException thrown by UserQueryImpl.userDisplayName when the displayName argument is null. The method sets an exact-match criterion on the user's display name and requires a concrete non-null string. The engine throws eagerly so misconfigured queries fail at the call site rather than during execution.","triggerScenarios":"Calling createUserQuery().userDisplayName(null), or chaining it with a value resolved from configuration, a tenant setting, or an entity attribute that was null.","commonSituations":"Tenant/organization display-name lookups where the configured name is missing; copying display names from users/records that lack the attribute; property files with the key absent yielding null.","solutions":["Pass a concrete display name: userDisplayName(\"John Doe\")","Apply the criterion conditionally: if (displayName != null) query.userDisplayName(displayName)","Verify the configuration/source actually contains the display-name value before querying","Use userDisplayNameLike(\"%doe%\") with a valid pattern when only a partial match is known"],"exampleFix":"// before\nUser user = identityService.createUserQuery().userDisplayName(config.getDisplayName()).singleResult();\n\n// after\nif (config.getDisplayName() == null) {\n    throw new IllegalStateException(\"display-name must be configured\");\n}\nUser user = identityService.createUserQuery().userDisplayName(config.getDisplayName()).singleResult();","handlingStrategy":"validation","validationCode":"if (displayName == null) { throw new IllegalArgumentException(\"displayName is required\"); }\nidentityService.createUserQuery().userDisplayName(displayName);","typeGuard":"boolean isPresent(String v) { return v != null && !v.trim().isEmpty(); }","tryCatchPattern":"try {\n    query.userDisplayName(displayName);\n} catch (FlowableIllegalArgumentException e) {\n    log.warn(\"Missing display-name criterion: {}\", e.getMessage());\n}","preventionTips":["Fail fast on missing configuration values (e.g. tenant display name) before querying","Null-check entity/attribute sources of the display name","Use conditional chaining when the criterion is optional","Prefer exact-match userDisplayName only with verified non-null values; use the Like variants for partial input"],"tags":["flowable","idm-engine","user-query","null-argument","display-name"],"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"}