{"record":{"id":"c59ad936d5cca44d","repo":"flowable/flowable-engine","slug":"no-decision-found-for-key-decisionkey-there-was","errorCode":null,"errorMessage":"No decision found for key <decisionKey>. There was also no fall back decision found for default tenant <defaultTenant>","messagePattern":"No decision found for key <decisionKey>\\. There was also no fall back decision found for default tenant <defaultTenant>","errorType":"exception","errorClass":"FlowableObjectNotFoundException","httpStatus":null,"severity":"error","filePath":"modules/flowable-dmn-engine/src/main/java/org/flowable/dmn/engine/impl/cmd/AbstractExecuteDecisionCmd.java","lineNumber":99,"sourceCode":"                new DmnDeploymentQueryImpl().parentDeploymentId(parentDeploymentId));\n\n            if (dmnDeployments != null && dmnDeployments.size() != 0) {\n                decision = decisionEntityManager.findDecisionByDeploymentAndKeyAndTenantId(\n                    dmnDeployments.get(0).getId(), decisionKey, tenantId);\n            }\n\n            if (decision == null) {\n                // If there is no decision table found linked to the deployment id, try to find one without a specific deployment id.\n                decision = decisionEntityManager.findLatestDecisionByKeyAndTenantId(decisionKey, tenantId);\n\n                if (decision == null) {\n                    // if fallback to default tenant is enabled do a final lookup query\n                    if (executeDecisionContext.isFallbackToDefaultTenant() || dmnEngineConfiguration.isFallbackToDefaultTenant()) {\n                        String defaultTenant = dmnEngineConfiguration.getDefaultTenantProvider().getDefaultTenant(tenantId, ScopeTypes.DMN, decisionKey);\n                        if (StringUtils.isNotEmpty(defaultTenant)) {\n                            decision = decisionEntityManager.findLatestDecisionByKeyAndTenantId(decisionKey, defaultTenant);\n                            if (decision == null) {\n                                throw new FlowableObjectNotFoundException(\"No decision found for key: \" + decisionKey +\n                                    \". There was also no fall back decision found for default tenant \" + defaultTenant);\n                            }\n                            \n                        } else {\n                            decision = decisionEntityManager.findLatestDecisionByKey(decisionKey);\n                            if (decision == null) {\n                                throw new FlowableObjectNotFoundException(\"No decision found for key: \" + decisionKey +\n                                    \". There was also no fall back decision table found without tenant.\");\n                            }\n                        }\n                        \n                    } else {\n                        throw new FlowableObjectNotFoundException(\"No decision found for key: \" + decisionKey +\n                            \", parent deployment id \" + parentDeploymentId + \" and tenant id: \" + tenantId +\n                            \". There was also no fall back decision found without parent deployment id.\");\n                    }\n                }\n            }","sourceCodeStart":81,"sourceCodeEnd":117,"githubUrl":"https://github.com/flowable/flowable-engine/blob/d6d39ce1c69ff244f2d9dc6af756a9b95e865586/modules/flowable-dmn-engine/src/main/java/org/flowable/dmn/engine/impl/cmd/AbstractExecuteDecisionCmd.java#L81-L117","documentation":"While resolving a decision by key with tenant fallback enabled, Flowable first queries by key and tenant, then falls back to the configured default tenant. If even that lookup returns null, it throws FlowableObjectNotFoundException indicating no decision exists for the key in the default tenant either.","triggerScenarios":"resolveDefinition in AbstractExecuteDecisionCmd: isFallbackToDefaultTenant() or engine config fallback enabled; findLatestDecisionByKeyAndTenantId(key, defaultTenant) returned null; DefaultTenantProvider returned a non-empty tenant.","commonSituations":"Decision deployed under a different tenant than the default; decision key typo or mismatched case; deployment never performed; fallback enabled but default tenant provider points at the wrong tenant.","solutions":["Verify the decision is deployed and check its TENANT_ID_ in ACT_DMN_DECISION","Correct the decisionKey passed to the execute call","Fix the DefaultTenantProvider to return the tenant the decision is actually deployed to","Remove/disable tenant filtering or deploy the DMN file to the expected tenant"],"exampleFix":"// before\nDmnEngineRule r = dmnEngine.execute(decisionKey, vars).getRuleExecutions(); // key 'myDecision'\n// after\nString decisionKey = \"decision_fraud_check\"; // exact deployed key\nDmnDecision d = dmnRepositoryService.createDecisionQuery().decisionKey(decisionKey).singleResult();","handlingStrategy":"try-catch","validationCode":"Decision d = dmnRepositoryService.createDecisionQuery()\n    .decisionKey(decisionKey).decisionTenantId(tenantId).singleResult();\nif (d == null && fallbackEnabled) d = dmnRepositoryService.createDecisionQuery()\n    .decisionKey(decisionKey).decisionTenantId(defaultTenant).singleResult();","typeGuard":null,"tryCatchPattern":"try { dmnEngine.executeDecisionByKey(tenantId, decisionKey, vars); }\ncatch (FlowableObjectNotFoundException e) {\n  LOG.warn(\"decision {} not found for tenant/default; check deployments\", decisionKey);\n  // deploy DMN or correct the key/tenant\n}","preventionTips":["Verify deployment tenant IDs in ACT_DMN_DECISION before executing","Keep decision keys in constants to avoid typos","Test tenant fallback configuration with both tenant-specific and default deployments"],"tags":["dmn","tenant","not-found","flowable"],"backgroundTag":"record-not-found","analyzedSha":"d6d39ce1c69ff244f2d9dc6af756a9b95e865586","analyzedAt":"2026-09-11T06:41:19.413Z","contentChangedAt":"2026-09-11T06:41:19.413Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}