flowable/flowable-engine · error · FlowableException

HitPolicy: %s violated; no output values present

Error message

HitPolicy: %s violated; no output values present

What it means

HitPolicyOutputOrder.composeDecisionResults sorts matching rule outputs for the PRIORITY/OUTPUT ORDER hit policy; this requires output values to be present. If no rule execution produced output values, strict mode throws FlowableException('HitPolicy: OUTPUT ORDER violated; no output values present'), otherwise it sets a validation message on the audit container.

Source

Thrown at modules/flowable-dmn-engine/src/main/java/org/flowable/dmn/engine/impl/hitpolicy/HitPolicyOutputOrder.java:56

    }

    @Override
    public void composeDecisionResults(final ELExecutionContext executionContext) {
        List<Map<String, Object>> ruleResults = new ArrayList<>(executionContext.getRuleResults().values());
        
        boolean outputValuesPresent = false;
        for (Map.Entry<String, List<Object>> entry : executionContext.getOutputValues().entrySet()) {
            List<Object> outputValues = entry.getValue();
            if (outputValues != null && !outputValues.isEmpty()) {
                outputValuesPresent = true;
                break;
            }
        }
        
        if (!outputValuesPresent) {
            String hitPolicyViolatedMessage = String.format("HitPolicy: %s violated; no output values present", getHitPolicyName());
            if (CommandContextUtil.getDmnEngineConfiguration().isStrictMode()) {
                throw new FlowableException(hitPolicyViolatedMessage);
            } else {
                executionContext.getAuditContainer().setValidationMessage(hitPolicyViolatedMessage);
            }
        }

        // sort on predefined list(s) of output values
        ruleResults.sort((o1, o2) -> {
            CompareToBuilder compareToBuilder = new CompareToBuilder();
            for (Map.Entry<String, List<Object>> entry : executionContext.getOutputValues().entrySet()) {
                List<Object> outputValues = entry.getValue();
                if (outputValues != null && !outputValues.isEmpty()) {
                    compareToBuilder.append(o1.get(entry.getKey()), o2.get(entry.getKey()),
                            new OutputOrderComparator<>(outputValues.toArray(new Comparable[outputValues.size()])));
                    compareToBuilder.toComparison();
                }
            }
            return compareToBuilder.toComparison();
        });

View on GitHub (pinned to d6d39ce1c6)

Solutions

  1. Fill in output values for the rules that can match under this hit policy
  2. Fix output expressions so they evaluate to non-empty values
  3. Review the DMN XML for empty <outputEntry> elements and correct them
  4. Test the table with the specific input values to confirm at least one matched rule yields an output

Example fix

// before (matched rule with empty output entry)
<outputEntry expressionLanguage="juel"><literalExpression/></outputEntry>
// after
<outputEntry expressionLanguage="juel"><literalExpression>low</literalExpression></outputEntry>
Defensive patterns

Strategy: validation

Validate before calling

// check every rule row has a non-empty output entry before deployment
rules.forEach(r -> { if (r.getOutputEntries().stream().allMatch(o -> o == null || o.getValue().isEmpty())) throw new IllegalStateException("rule " + r + " has no output values"); });

Try / catch

try { decisionTable.execute(input); } catch (FlowableException e) { if (e.getMessage().contains("no output values present")) { fillOutputValues(); } throw e; }

Prevention

When it happens

Trigger: Running a decision table with hit policy PRIORITY/OUTPUT ORDER where matched rules exist but their output entries carry no values (empty output expressions or outputs never assigned).

Common situations: Decision table rows with empty output cells; output expressions that evaluate to null/empty; incomplete DMN model authored in an external tool; wrong output column mapping after editing the table.

Understand the failure class

Background: Schema validation failed / invalid input schema: payload rejected because its shape doesn't match the expected schema — this error's family across 28 libraries.

Related errors


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