flowable/flowable-engine · error · FlowableException

No decision table found with id ${decisionTableId}

Error message

No decision table found with id ${decisionTableId}

What it means

DecisionUtil.getDecisionTableFromDatabase looks up a DecisionEntity by id through the DecisionEntityManager. When findById returns null — no decision table with that id is persisted in the DMN engine's ACT_DMN_DATABASE tables — it throws FlowableException('No decision table found with id ' + decisionTableId). It signals the id does not correspond to any deployed DMN decision table.

Source

Thrown at modules/flowable-dmn-engine/src/main/java/org/flowable/dmn/engine/impl/util/DecisionUtil.java:71

        // This will check the cache in the findDeployedDecisionById and resolveDecisionTable method
        DecisionEntity decisionTableEntity = deploymentManager.findDeployedDecisionById(decisionId);
        return deploymentManager.resolveDecision(decisionTableEntity).getDmnDefinition();
    }

    public static DmnDefinition getDmnDefinitionFromCache(String definitionId) {
        DecisionCacheEntry cacheEntry = CommandContextUtil.getDmnEngineConfiguration().getDefinitionCache().get(definitionId);
        if (cacheEntry != null) {
            return cacheEntry.getDmnDefinition();
        }
        return null;
    }

    public static DecisionEntity getDecisionTableFromDatabase(String decisionTableId) {
        DecisionEntityManager decisionTableEntityManager = CommandContextUtil.getDmnEngineConfiguration().getDecisionEntityManager();
        DecisionEntity decisionTable = decisionTableEntityManager.findById(decisionTableId);
        if (decisionTable == null) {
            throw new FlowableException("No decision table found with id " + decisionTableId);
        }

        return decisionTable;
    }

    public static DecisionService getDecisionService(String decisionId) {
        DmnDefinition dmnDefinition = getDmnDefinitionByDecisionId(decisionId);
        DecisionService decisionService = dmnDefinition.getDecisionServiceById(decisionId);

        if (decisionService == null) {
            throw new FlowableObjectNotFoundException("Could not find decision service with id: " + decisionId);
        }

        return decisionService;
    }
}

View on GitHub (pinned to d6d39ce1c6)

Solutions

  1. Verify the id exists by querying the DMN repository (dmnRepositoryService.createDecisionTableQuery().decisionTableId(id).singleResult()) before executing the decision.
  2. Deploy the DMN definition first (DmnDeploymentBuilder.deploy()) and use the id of the newly deployed DecisionEntity instead of a hard-coded value.
  3. Check the DMN engine configuration points at the correct datasource/schema that actually contains the deployment.
  4. Inspect ACT_DMN_DECISION (or equivalent) in the database to confirm the row exists; if not, re-run the deployment.

Example fix

// before
DecisionEntity decision = dmnRuleService.executeDecisionById("myTable-1", variables); // id may not be deployed
// after
DecisionTable dt = dmnRepositoryService.createDecisionTableQuery().decisionTableId("myTable-1").singleResult();
if (dt == null) {
    dmnRepositoryService.createDeployment().addClasspathResource("dmn/myTable.dmn").deploy();
}
DecisionEntity decision = dmnRuleService.executeDecisionById("myTable-1", variables);
Defensive patterns

Strategy: validation

Validate before calling

DecisionTable dt = dmnRepositoryService.createDecisionTableQuery()
    .decisionTableId(decisionTableId)
    .singleResult();
if (dt == null) {
    throw new IllegalStateException("Decision table not deployed: " + decisionTableId);
}

Try / catch

try {
    dmnRuleService.executeDecisionById(decisionTableId, variables);
} catch (FlowableException e) {
    if (e.getMessage().startsWith("No decision table found with id")) {
        // deploy missing definition or fail with a clear message
        throw new MissingDecisionTableException(decisionTableId, e);
    }
    throw e;
}

Prevention

When it happens

Trigger: Calling the DMN rule runtime (DmnRuleService/DecisionUtil.getDecisionTableFromDatabase) with a decisionTableId that was never deployed, was deployed to a different database/schema, was deleted, or where the engine configuration points at the wrong datasource.

Common situations: Hard-coding ids copied from another environment (dev vs prod database), database not initialized or Flyway/Liquibase migrations missing DMN tables, running against an in-memory H2 that was wiped between restarts, tenant-specific deployments where the id exists only in another tenant, or a version upgrade/redeploy that replaced the id.

Understand the failure class

Background: "Not found" and "does not exist" errors: why "Task not found", "No such folder", and "Can't find" fire when a lookup comes back empty — this error's family across 14 libraries.

Related errors


AI-assisted analysis of flowable/flowable-engine@d6d39ce1c6 (2026-09-11). Data as JSON: /api/errors/e3dda1d436437f5a. Report an issue: GitHub.