flowable/flowable-engine · error · FlowableException
Cannot fail external jobs. There is no BPMN or CMMN engine…
Error message
Cannot fail external jobs. There is no BPMN or CMMN engine available
What it means
FlowableException thrown by createExternalWorkerJobFailureBuilder when both the BPMN managementService and CMMN cmmnManagementService are null while a worker tries to report a job failure. Failing an external job requires an engine to route the failure to. Symmetric to the acquire-side check but on the failure path.
Solutions
- Ensure a BPMN or CMMN engine is configured so its ManagementService is injected into the resource.
- Verify engine auto-configuration is enabled and the datasource is valid.
- Inspect startup logs to confirm the engine (and its services) initialized successfully.
Example fix
// before: no engine config in application.yml
// after
flowable:
process:
enabled: true
cmmn:
enabled: true Defensive patterns
Strategy: fallback
Validate before calling
if (processEngine == null && cmmnEngine == null) { throw new IllegalStateException("Cannot report failures: no engine configured"); } Try / catch
try { failureBuilder(jobId, workerId).failure(message); } catch (FlowableException e) { if (e.getMessage().contains("Cannot fail external jobs")) { alertOps("Engine misconfiguration"); } } Prevention
- Verify engine beans are present before starting workers
- Add a health check that fails fast when no ManagementService exists
- Keep BPMN or CMMN engine enabled in deployment config
When it happens
Trigger: POST to the external worker job failure endpoint (failureBuilder path) on a deployment where neither engine's ManagementService is wired into ExternalWorkerAcquireJobResource.
Common situations: REST module deployed standalone without engine beans; misconfigured Spring context excluding ProcessEngine/CmmnEngine services; engine startup failure.
Understand the failure class
Background: "not installed", "pip install", "required for": how missing-dependency errors surface across open-source libraries — this error's family across 34 libraries.
Related errors
- Cannot acquire external jobs. There is no BPMN or CMMN…
- Cannot unacquire BPMN job. There is no BPMN engine available
- Cannot unacquire external jobs. There is no BPMN or CMMN…
- Cannot unacquire CMMN job. There is no CMMN engine available
- Can only unacquire BPMN or CMMN external job. Job with id
AI-assisted analysis of flowable/flowable-engine@d6d39ce1c6 (2026-09-11).
Data as JSON: /api/errors/dc637ebcfded7fd4.
Report an issue: GitHub.
Appendix: source
Thrown at modules/flowable-external-job-rest/src/main/java/org/flowable/external/job/rest/service/api/acquire/ExternalWorkerAcquireJobResource.java:306
}
protected ExternalWorkerJobAcquireBuilder createExternalWorkerAcquireBuilder() {
if (managementService != null) {
return managementService.createExternalWorkerJobAcquireBuilder();
} else if (cmmnManagementService != null) {
return cmmnManagementService.createExternalWorkerJobAcquireBuilder();
} else {
throw new FlowableException("Cannot acquire external jobs. There is no BPMN or CMMN engine available");
}
}
protected ExternalWorkerJobFailureBuilder createExternalWorkerJobFailureBuilder(String jobId, String workerId) {
if (managementService != null) {
return managementService.createExternalWorkerJobFailureBuilder(jobId, workerId);
} else if (cmmnManagementService != null) {
return cmmnManagementService.createExternalWorkerJobFailureBuilder(jobId, workerId);
} else {
throw new FlowableException("Cannot fail external jobs. There is no BPMN or CMMN engine available");
}
}
}
View on GitHub (pinned to d6d39ce1c6)