{"record":{"id":"c094550ebf240f2b","repo":"flowable/flowable-engine","slug":"one-of-the-attributes-type-or-operation-is-man","errorCode":null,"errorMessage":"One of the attributes 'type' or 'operation' is mandatory on sendTask {}","messagePattern":"One of the attributes 'type' or 'operation' is mandatory on sendTask (.+?)","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"modules/flowable5-engine/src/main/java/org/activiti/engine/impl/bpmn/parser/handler/SendTaskParseHandler.java","lineNumber":61,"sourceCode":"        activity.setAsync(sendTask.isAsynchronous());\n        activity.setExclusive(!sendTask.isNotExclusive());\n\n        if (StringUtils.isNotEmpty(sendTask.getType())) {\n            if (\"mail\".equalsIgnoreCase(sendTask.getType())) {\n                activity.setActivityBehavior(bpmnParse.getActivityBehaviorFactory().createMailActivityBehavior(sendTask));\n            } else if (\"camel\".equalsIgnoreCase(sendTask.getType())) {\n                activity.setActivityBehavior(bpmnParse.getActivityBehaviorFactory().createCamelActivityBehavior(sendTask, bpmnParse.getBpmnModel()));\n            }\n\n            // for web service\n        } else if (ImplementationType.IMPLEMENTATION_TYPE_WEBSERVICE.equalsIgnoreCase(sendTask.getImplementationType()) &&\n                StringUtils.isNotEmpty(sendTask.getOperationRef())) {\n\n            WebServiceActivityBehavior webServiceActivityBehavior = bpmnParse.getActivityBehaviorFactory().createWebServiceActivityBehavior(sendTask, bpmnParse.getBpmnModel());\n            activity.setActivityBehavior(webServiceActivityBehavior);\n\n        } else {\n            LOGGER.warn(\"One of the attributes 'type' or 'operation' is mandatory on sendTask {}\", sendTask.getId());\n        }\n    }\n\n}\n","sourceCodeStart":43,"sourceCodeEnd":66,"githubUrl":"https://github.com/flowable/flowable-engine/blob/d6d39ce1c69ff244f2d9dc6af756a9b95e865586/modules/flowable5-engine/src/main/java/org/activiti/engine/impl/bpmn/parser/handler/SendTaskParseHandler.java#L43-L66","documentation":"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.","triggerScenarios":"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.","commonSituations":"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.","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"],"exampleFix":"// before\n<sendTask id=\"send1\"/>\n// after\n<sendTask id=\"send1\" operationRef=\"tns:sendOperation\"/>","handlingStrategy":"validation","validationCode":"for (SendTask t : model.getFlowElementsOfType(SendTask.class)) {\n    if (isEmpty(t.getType()) && isEmpty(t.getOperationRef())) {\n        throw new IllegalArgumentException(\"sendTask \" + t.getId() + \" needs 'type' or 'operationRef'\");\n    }\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["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"],"tags":["bpmn","parsing","send-task","missing-attribute"],"backgroundTag":"missing-required-argument","analyzedSha":"d6d39ce1c69ff244f2d9dc6af756a9b95e865586","analyzedAt":"2026-09-11T06:41:19.413Z","contentChangedAt":"2026-09-11T06:41:19.413Z","schemaVersion":2},"datasetVersion":"2026-09-18T11:17:12.947Z"}