flowable/flowable-engine · error · FlowableException
Cannot migrate case(es), not enough information
Error message
Cannot migrate case(es), not enough information
What it means
HistoricCaseInstanceMigrationCmd.execute() dispatches the migration in three modes: by case definition id, or by key plus version (>=0), or otherwise fails. This FlowableException is thrown in the else branch when none of those combinations identify a source case definition, meaning the command was constructed without enough identifying information.
Solutions
- Set both the case definition key AND version (>=0) on the migration builder/command
- Alternatively provide an explicit case definition id so the first dispatch branch is used
- Log/inspect the builder state before execute() to confirm one of the valid identifier combinations is present
Example fix
// before
builder.migrate("myCaseDef"); // no version set -> version == -1
// after
builder.migrate("myCaseDef", 2); // key + version
Defensive patterns
Strategy: validation
Validate before calling
boolean enough = caseDefinitionId != null || (caseDefinitionKey != null && caseDefinitionVersion >= 0); if (!enough) throw new IllegalArgumentException("Provide case definition id, or key plus version"); Try / catch
try { cmmnMigrationService.migrate(...); } catch (FlowableException e) { if (e.getMessage().contains("not enough information")) { /* complete builder params and retry */ } } Prevention
- Always set key AND version together when not using a definition id
- Inspect builder state before execute() (assert one valid identifier combo)
- Use HistoricCaseInstanceMigrationBuilder instead of raw commands so defaults are enforced
When it happens
Trigger: Executing the migration command when caseDefinitionId is null AND (caseDefinitionKey is null OR caseDefinitionVersion < 0) — e.g. a key was set but version was left unset (stays -1), or only the tenant/document were provided.
Common situations: Builders where setToCaseDefinitionVersion() was never called so version remains -1; mixing migration modes and assuming the engine can default to the latest version; hand-constructed commands missing the id field.
Understand the failure class
Background: "missing required argument" and "the following required arguments were not provided": what required-argument errors mean and how to fix them — this error's family across 20 libraries.
Related errors
- Cannot migrate historic case instances, not enough…
- Must specify a case definition id to migrate
- Must specify a case definition id to migrate
- Must specify a case definition tenant id to migrate
- Must specify a historic case instance id to migrate
AI-assisted analysis of flowable/flowable-engine@d6d39ce1c6 (2026-09-11).
Data as JSON: /api/errors/9b6eae233567097b.
Report an issue: GitHub.
Appendix: source
Thrown at modules/flowable-cmmn-engine/src/main/java/org/flowable/cmmn/engine/impl/cmd/HistoricCaseInstanceMigrationCmd.java:96
this.caseDefinitionVersion = caseDefinitionVersion;
this.caseDefinitionTenantId = caseDefinitionTenantId;
this.historicCaseInstanceMigrationDocument = historicCaseInstanceMigrationDocument;
this.cmmnEngineConfiguration = cmmnEngineConfiguration;
}
@Override
public Void execute(CommandContext commandContext) {
CaseInstanceMigrationManager migrationManager = cmmnEngineConfiguration.getCaseInstanceMigrationManager();
if (caseInstanceId != null) {
migrationManager.migrateHistoricCaseInstance(caseInstanceId, historicCaseInstanceMigrationDocument, commandContext);
} else if (caseDefinitionId != null) {
migrationManager.migrateHistoricCaseInstancesOfCaseDefinition(caseDefinitionId, historicCaseInstanceMigrationDocument, commandContext);
} else if (caseDefinitionKey != null && caseDefinitionVersion >= 0) {
migrationManager.migrateHistoricCaseInstancesOfCaseDefinition(caseDefinitionKey, caseDefinitionVersion,
caseDefinitionTenantId, historicCaseInstanceMigrationDocument, commandContext);
} else {
throw new FlowableException("Cannot migrate case(es), not enough information");
}
return null;
}
}
View on GitHub (pinned to d6d39ce1c6)