flowable/flowable-engine · error · FlowableIllegalArgumentException
ids are null
Error message
ids are null
What it means
ChannelDefinitionQueryImpl.deploymentIds() throws FlowableIllegalArgumentException when the passed Set<String> of deployment IDs is null. The Flowable query builders validate every filter argument eagerly so that invalid queries fail at construction time with a clear message rather than producing a broken SQL query or a confusing persistence-layer error later.
Solutions
- Ensure a non-null Set is passed, e.g. deploymentIds(Collections.singleton(deploymentId))
- If no deployment filter is wanted, do not call deploymentIds() at all instead of passing null
- Guard the call site: only invoke deploymentIds(ids) when ids != null && !ids.isEmpty()
- Initialize the Set with new HashSet<>() before use instead of leaving the variable null
Example fix
// before
Set<String> ids = getConfiguredDeploymentIds(); // may return null
query.deploymentIds(ids);
// after
Set<String> ids = getConfiguredDeploymentIds();
if (ids != null && !ids.isEmpty()) {
query.deploymentIds(ids);
} Defensive patterns
Strategy: validation
Validate before calling
if (deploymentIds == null || deploymentIds.isEmpty()) {
throw new IllegalArgumentException("deploymentIds must be a non-empty set");
}
query.deploymentIds(deploymentIds); Type guard
boolean hasDeploymentIds(Set<String> ids) {
return ids != null && !ids.isEmpty();
} Try / catch
try {
query.deploymentIds(ids);
} catch (FlowableIllegalArgumentException e) {
logger.warn("Invalid deploymentIds filter: {}", e.getMessage());
// proceed with an unfiltered query or rethrow as a client error
} Prevention
- Never pass null to query filter methods; omit the filter call instead
- Initialize Set fields eagerly (new HashSet<>()) so they are never null
- Use Collections.singleton(id) when filtering on a single deployment
- Validate query inputs at the API boundary before building Flowable queries
When it happens
Trigger: Calling channelDefinitionQuery().deploymentIds(null) directly, or passing a Set<String> variable that was never initialized (e.g. a method parameter or a collected set that came back null from another API).
Common situations: Building the query from configuration/properties where deployment IDs were not configured; refactoring code that used deploymentId(String) into a set and forgetting initialization; passing a nullable variable returned by another service.
Related errors
- Error retrieving app engine info
- implementation is null
- key is null
- keyLike is null
- keyLikeIgnoreCase is null
AI-assisted analysis of flowable/flowable-engine@d6d39ce1c6 (2026-09-11).
Data as JSON: /api/errors/2c264e143ea17709.
Report an issue: GitHub.
Appendix: source
Thrown at modules/flowable-event-registry/src/main/java/org/flowable/eventregistry/impl/ChannelDefinitionQueryImpl.java:155
throw new FlowableIllegalArgumentException("nameLikeIgnoreCase is null");
}
this.nameLikeIgnoreCase = nameLikeIgnoreCase;
return this;
}
@Override
public ChannelDefinitionQueryImpl deploymentId(String deploymentId) {
if (deploymentId == null) {
throw new FlowableIllegalArgumentException("id is null");
}
this.deploymentId = deploymentId;
return this;
}
@Override
public ChannelDefinitionQueryImpl deploymentIds(Set<String> deploymentIds) {
if (deploymentIds == null) {
throw new FlowableIllegalArgumentException("ids are null");
}
this.deploymentIds = deploymentIds;
return this;
}
@Override
public ChannelDefinitionQueryImpl parentDeploymentId(String parentDeploymentId) {
if (parentDeploymentId == null) {
throw new FlowableIllegalArgumentException("parentDeploymentId is null");
}
this.parentDeploymentId = parentDeploymentId;
return this;
}
@Override
public ChannelDefinitionQueryImpl channelDefinitionKey(String key) {
if (key == null) {
throw new FlowableIllegalArgumentException("key is null");View on GitHub (pinned to d6d39ce1c6)