flowable/flowable-engine · error · FlowableException
HitPolicy: %s has aggregation: %s and multiple outputs. This
Error message
HitPolicy: %s has aggregation: %s and multiple outputs. This is not supported
What it means
A COLLECT hit policy with an aggregator (SUM/MIN/MAX/COUNT) combined with multiple output columns is not supported by Flowable DMN; the aggregation can only apply to a single numeric output. The engine performs this sanity check before executing the decision table.
Source
Thrown at modules/flowable-dmn-engine/src/main/java/org/flowable/dmn/engine/impl/RuleEngineExecutorImpl.java:326
protected AbstractHitPolicy getHitPolicyBehavior(HitPolicy hitPolicy) {
AbstractHitPolicy hitPolicyBehavior = hitPolicyBehaviors.get(hitPolicy.getValue());
if (hitPolicyBehavior == null) {
String hitPolicyBehaviorNotFoundMessage = String.format("HitPolicy behavior: %s not configured", hitPolicy.getValue());
LOGGER.error(hitPolicyBehaviorNotFoundMessage);
throw new FlowableException(hitPolicyBehaviorNotFoundMessage);
}
return hitPolicyBehavior;
}
protected void sanityCheckDecisionTable(DecisionTable decisionTable) {
if (decisionTable.getHitPolicy() == HitPolicy.COLLECT && decisionTable.getAggregation() != null && decisionTable.getOutputs() != null) {
if (decisionTable.getOutputs().size() > 1) {
throw new FlowableException(String.format("HitPolicy: %s has aggregation: %s and multiple outputs. This is not supported", decisionTable.getHitPolicy(), decisionTable.getAggregation()));
}
if (!"number".equals(decisionTable.getOutputs().get(0).getTypeRef())) {
throw new FlowableException(String.format("HitPolicy: %s has aggregation: %s needs output type number", decisionTable.getHitPolicy(), decisionTable.getAggregation()));
}
}
}
@Override
public Map<String, AbstractHitPolicy> getHitPolicyBehaviors() {
return hitPolicyBehaviors;
}
@Override
public void setHitPolicyBehaviors(Map<String, AbstractHitPolicy> hitPolicyBehaviors) {
this.hitPolicyBehaviors = hitPolicyBehaviors;
}
@OverrideView on GitHub (pinned to d6d39ce1c6)
Solutions
- Remove the extra output columns so only one output remains
- Split the decision table into multiple tables, one per aggregated output
- Change the hit policy (e.g. plain COLLECT without aggregation, or RULE ORDER/OUTPUT ORDER) if multiple outputs are needed
- Validate the DMN XML against Flowable's supported feature set before deployment
Example fix
// before <hitPolicy>COLLECT</hitPolicy> <aggregation>SUM</aggregation> <!-- two outputs --> // after <hitPolicy>COLLECT</hitPolicy> <aggregation>SUM</aggregation> <!-- single output column only -->
Defensive patterns
Strategy: validation
Validate before calling
if (dt.getHitPolicy() == HitPolicy.COLLECT && dt.getAggregation() != null && dt.getOutputs() != null && dt.getOutputs().size() > 1) {
throw new IllegalArgumentException("COLLECT+aggregation supports only one output");
} Prevention
- Enforce single-output COLLECT tables in your modeling guidelines
- Re-export tables from other DMN tools and review unsupported combos
- Add a schema/feature check in the deployment pipeline
When it happens
Trigger: execute -> sanityCheckDecisionTable finds decisionTable.getHitPolicy() == COLLECT, aggregation != null, and outputs.size() > 1.
Common situations: DMN tables exported from other DMN tools (Camunda, Trisotech, editors) that permit aggregated COLLECT with multiple outputs, then deployed to Flowable.
Understand the failure class
Background: UnsupportedOperationException and "is not supported" errors: when a library deliberately refuses a call — this error's family across 30 libraries.
Related errors
- more than one result in decision:
- more than one result
- HitPolicy behavior: %s not configured
- HitPolicy: %s has aggregation: %s needs output type number
- decision table does not contain a hit policy
AI-assisted analysis of flowable/flowable-engine@d6d39ce1c6 (2026-09-11).
Data as JSON: /api/errors/2a707b6ffc2b3842.
Report an issue: GitHub.