flowable/flowable-engine · error · FlowableException
deployment '${deploymentId}' didn't put channel definition '
Error message
deployment '${deploymentId}' didn't put channel definition '${channelDefinitionId}' in the cache What it means
FlowableException raised in resolveChannelDefinition: after lazily re-deploying a deployment, the channelDefinitionCache still contains no entry for channelDefinitionId. It mirrors error 2872 but for channel definitions, meaning the re-deploy did not register the requested channel definition in the cache.
Source
Thrown at modules/flowable-event-registry/src/main/java/org/flowable/eventregistry/impl/persistence/deploy/EventDeploymentManager.java:218
public ChannelDefinitionCacheEntry resolveChannelDefinition(ChannelDefinition channelDefinition) {
String channelDefinitionId = channelDefinition.getId();
String deploymentId = channelDefinition.getDeploymentId();
ChannelDefinitionCacheEntry cachedChannelDefinition = channelDefinitionCache.get(channelDefinitionId);
if (cachedChannelDefinition == null) {
EventDeploymentEntity deployment = engineConfig.getDeploymentEntityManager().findById(deploymentId);
List<EventResourceEntity> resources = engineConfig.getResourceEntityManager().findResourcesByDeploymentId(deploymentId);
for (EventResourceEntity resource : resources) {
deployment.addResource(resource);
}
deployment.setNew(false);
deploy(deployment);
cachedChannelDefinition = channelDefinitionCache.get(channelDefinitionId);
if (cachedChannelDefinition == null) {
throw new FlowableException("deployment '" + deploymentId + "' didn't put channel definition '" + channelDefinitionId + "' in the cache");
}
}
return cachedChannelDefinition;
}
public void removeDeployment(String deploymentId) {
EventDeploymentEntity deployment = deploymentEntityManager.findById(deploymentId);
if (deployment == null) {
throw new FlowableObjectNotFoundException("Could not find a deployment with id '" + deploymentId + "'.");
}
// Remove any event and channel definition from the cache
List<EventDefinition> eventDefinitions = new EventDefinitionQueryImpl().deploymentId(deploymentId).list();
List<ChannelDefinition> channelDefinitions = new ChannelDefinitionQueryImpl().deploymentId(deploymentId).list();
// Delete data
deploymentEntityManager.deleteDeployment(deploymentId);
View on GitHub (pinned to d6d39ce1c6)
Solutions
- Verify the deployment still contains the channel model resource for this definition id.
- Redeploy the channel definition cleanly and confirm it appears via ChannelDefinitionQuery.deploymentId(...).
- Inspect the event registry deployer pipeline to ensure channel models are parsed and cached.
- Remove orphaned channel definition rows or the whole broken deployment and redeploy.
Example fix
// before
ChannelDefinitionEntity ch = eventDeploymentManager.findDeployedChannelDefinitionById(channelId);
// after
ChannelDefinition ch = eventRepositoryService.createChannelDefinitionQuery().deploymentId(deploymentId).list()
.stream().filter(c -> c.getId().equals(channelId)).findFirst()
.orElseThrow(() -> new IllegalStateException("channel missing, redeploy deployment " + deploymentId)); Defensive patterns
Strategy: fallback
Validate before calling
ChannelDefinition ch = eventRepositoryService.createChannelDefinitionQuery().deploymentId(deploymentId).list()
.stream().filter(c -> c.getId().equals(channelDefinitionId)).findFirst().orElse(null);
if (ch == null) throw new IllegalStateException("channel " + channelDefinitionId + " missing from deployment " + deploymentId); Try / catch
try {
entry = manager.findDeployedChannelDefinitionById(channelDefinitionId);
} catch (FlowableException e) {
throw new IllegalStateException("channel deployment data inconsistent, redeploy " + deploymentId, e);
} Prevention
- Keep channel model resources intact in the deployment store; don't purge resources independently.
- Test custom channel model processors against the default deployer pipeline.
- Redeploy whole deployments, never patch single definition rows.
- Validate cache configuration changes against channel definition resolution.
When it happens
Trigger: Calling any findDeployedChannelDefinition* method for an id whose parent deployment is not in the deployment cache, then the redeploy fails to produce a ChannelDefinitionCacheEntry for that id (missing/inaccessible channel resource, deployer skipping it).
Common situations: Database rows for channel definitions whose XML/JSON resources were lost; custom ChannelModelProcessor not registering the model; failed migration leaving orphaned definitions; cache configured to drop entries without redeploy support.
Understand the failure class
Background: "This is a bug, please report it": internal invariant violations, unreachable panics, and SNH errors explained — this error's family across 47 libraries.
Related errors
- No channel keys configured for ${execution}
- Error parsing channel definition JSON
- deployment '${deploymentId}' didn't put event definition '${
- deployment '' didn't put app definition '' in the cache
- No channel keys configured for ${planItemInstanceEntity}
AI-assisted analysis of flowable/flowable-engine@d6d39ce1c6 (2026-09-11).
Data as JSON: /api/errors/ee2fa169f7f17ba1.
Report an issue: GitHub.