flowable/flowable-engine · warning
One of the attributes 'type' or 'operation' is mandatory on…
Error message
One of the attributes 'type' or 'operation' is mandatory on sendTask {} What it means
A sendTask in the BPMN XML lacks any of the attributes that determine its behavior: a 'type' (e.g. mail/mule/camel) or an 'operation' reference (web service). The parser logs this warning and does not assign an activity behavior, so the send task would do nothing or misbehave at runtime.
Solutions
- Set the operationRef attribute (with an interface/operation defined via imports) for a web-service send task
- Set the type attribute (e.g. "mail", "mule", "camel") for a built-in send task type
- Remove or convert the sendTask to a serviceTask/class implementation if neither applies
Example fix
// before <sendTask id="send1"/> // after <sendTask id="send1" operationRef="tns:sendOperation"/>
Defensive patterns
Strategy: validation
Validate before calling
for (SendTask t : model.getFlowElementsOfType(SendTask.class)) {
if (isEmpty(t.getType()) && isEmpty(t.getOperationRef())) {
throw new IllegalArgumentException("sendTask " + t.getId() + " needs 'type' or 'operationRef'");
}
} Prevention
- Configure type or operationRef whenever a send task is added to a diagram
- Include web-service imports/operations when using operationRef
- Run process validation as part of the build/deploy pipeline
When it happens
Trigger: executeParse of a SendTask where type is empty AND neither operationRef nor other web-service attributes are set — the final else branch of the type/operation dispatch.
Common situations: Send task dragged into the diagram but never configured; imported BPMN from tools that use different send-task attribute conventions; refactoring that dropped the operationRef.
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
- One of the attributes 'class', 'delegateExpression'…
- Activity needed for multi instance cannot bv found
- end event with cancelEventDefinition only supported inside…
- Error parsing XML
- Error parsing XML
AI-assisted analysis of flowable/flowable-engine@d6d39ce1c6 (2026-09-11).
Data as JSON: /api/errors/c094550ebf240f2b.
Report an issue: GitHub.
Appendix: source
Thrown at modules/flowable5-engine/src/main/java/org/activiti/engine/impl/bpmn/parser/handler/SendTaskParseHandler.java:61
activity.setAsync(sendTask.isAsynchronous());
activity.setExclusive(!sendTask.isNotExclusive());
if (StringUtils.isNotEmpty(sendTask.getType())) {
if ("mail".equalsIgnoreCase(sendTask.getType())) {
activity.setActivityBehavior(bpmnParse.getActivityBehaviorFactory().createMailActivityBehavior(sendTask));
} else if ("camel".equalsIgnoreCase(sendTask.getType())) {
activity.setActivityBehavior(bpmnParse.getActivityBehaviorFactory().createCamelActivityBehavior(sendTask, bpmnParse.getBpmnModel()));
}
// for web service
} else if (ImplementationType.IMPLEMENTATION_TYPE_WEBSERVICE.equalsIgnoreCase(sendTask.getImplementationType()) &&
StringUtils.isNotEmpty(sendTask.getOperationRef())) {
WebServiceActivityBehavior webServiceActivityBehavior = bpmnParse.getActivityBehaviorFactory().createWebServiceActivityBehavior(sendTask, bpmnParse.getBpmnModel());
activity.setActivityBehavior(webServiceActivityBehavior);
} else {
LOGGER.warn("One of the attributes 'type' or 'operation' is mandatory on sendTask {}", sendTask.getId());
}
}
}
View on GitHub (pinned to d6d39ce1c6)