flowable/flowable-engine · error · ActivitiException
Message dispatcher is disabled, cannot dispatch event
Error message
Message dispatcher is disabled, cannot dispatch event
What it means
This command requires the process engine's event dispatcher to be enabled. If eventDispatcher.isEnabled() is false (events support turned off in configuration), dispatching is impossible and an ActivitiException is thrown rather than silently dropping the event.
Solutions
- Enable the event dispatcher: processEngineConfiguration.setEventDispatcherEnabled(true)
- Remove or gate the dispatchEvent call behind a check of configuration.isEventDispatcherEnabled()
- Align configuration between environments so event support is enabled wherever dispatch code runs
Example fix
// before
runtimeService.dispatchEvent(event);
// after
if (processEngine.getProcessEngineConfiguration().getEventDispatcher().isEnabled()) {
runtimeService.dispatchEvent(event);
} Defensive patterns
Strategy: validation
Validate before calling
if (!processEngine.getProcessEngineConfiguration().getEventDispatcher().isEnabled()) { throw new IllegalStateException("Event dispatcher is disabled"); } Type guard
boolean canDispatch(ProcessEngine pe) { return pe.getProcessEngineConfiguration().getEventDispatcher().isEnabled(); } Try / catch
try { runtimeService.dispatchEvent(event); } catch (ActivitiException e) { LOGGER.warn("Event dispatch failed: {}", e.getMessage()); } Prevention
- Keep event dispatcher enabled in all environments that run dispatching code
- Gate dispatch calls behind an isEventDispatcherEnabled() check
- Document configuration dependencies for any module dispatching events
When it happens
Trigger: Calling runtimeService.dispatchEvent(event) on an engine configured with event support disabled, i.e. processEngineConfiguration.setEventDispatcherEnabled(false) or an equivalent Spring Boot property.
Common situations: Teams that disabled event logging/Dispatch for performance, then deployed code (custom listeners, integrations) that still dispatches events; copy-pasted configuration across environments.
Related errors
- Message dispatcher is disabled, cannot dispatch event.
- A channel key detection value is required for the channel…
- A datasource is required for initializing the engine
- ackMode in definition
- At least one of topics, topicPartitions or topicPattern…
AI-assisted analysis of flowable/flowable-engine@d6d39ce1c6 (2026-09-11).
Data as JSON: /api/errors/fddb1d9fb9d0475a.
Report an issue: GitHub.
Appendix: source
Thrown at modules/flowable5-engine/src/main/java/org/activiti/engine/impl/cmd/DispatchEventCommand.java:44
*/
public class DispatchEventCommand implements Command<Void> {
protected FlowableEvent event;
public DispatchEventCommand(FlowableEvent event) {
this.event = event;
}
@Override
public Void execute(CommandContext commandContext) {
if (event == null) {
throw new ActivitiIllegalArgumentException("event is null");
}
if (commandContext.getEventDispatcher().isEnabled()) {
commandContext.getEventDispatcher().dispatchEvent(event, EngineConfigurationConstants.KEY_PROCESS_ENGINE_CONFIG);
} else {
throw new ActivitiException("Message dispatcher is disabled, cannot dispatch event");
}
return null;
}
}
View on GitHub (pinned to d6d39ce1c6)