如何在camunda驾驶舱上执行邮件任务流程?

时间:2017-07-05 19:52:03

标签: java node.js camunda camunda-modeler

我们的工作流程附带了服务任务,下面的模板应用于bmpn:serviceTask,现在当我们使用https://engine-rest/deployment/create将工作流部署到camunda时,我们可以运行该流程,但是我们看到了这个错误在事件选项卡上,我们使用bpmn-js节点库进行建模并创建工作流,我们在其中定义camunda:class,因为您可以看到下面的错误,任何想法如何解决这个camunda类问题?

我们只是在流程启动时尝试发送电子邮件通知?

对camunda的新东西,任何帮助将不胜感激。

template.js

{
  "name": "Mail_Task_2",
  "id": "com.camunda.example.MailTask_2",
  "createdBy": "sh529u",
  "users": [],
  "groups": [],
  "properties": [
    {
      "binding": {
        "name": "camunda:class",
        "type": "property"
      },
      "editable": false,
      "value": "com.mycompany.MailTaskImpl",
      "type": "String",
      "label": "Implementation Type"
    },
    {
      "label": "Sender",
      "type": "String",
      "binding": {
        "type": "camunda:inputParameter",
        "name": "sender"
      },
      "constraints": {
        "notEmpty": true
      }
    },
    {
      "label": "Receivers",
      "type": "String",
      "binding": {
        "type": "camunda:inputParameter",
        "name": "receivers"
      },
      "constraints": {
        "notEmpty": true
      }
    },
    {
      "label": "Template",
      "description": "By the way, you can use freemarker templates here",
      "value": "Hello ${firstName}!",
      "type": "Text",
      "binding": {
        "type": "camunda:inputParameter",
        "name": "messageBody",
        "scriptFormat": "freemarker"
      },
      "constraints": {
        "notEmpty": true
      }
    },
    {
      "label": "Result Status",
      "description": "The process variable to which to assign the send result to",
      "type": "String",
      "value": "mailSendResult",
      "binding": {
        "type": "camunda:outputParameter",
        "source": "${ resultStatus }"
      }
    },
    {
      "label": "Send Async?",
      "type": "Boolean",
      "value": true,
      "binding": {
        "type": "property",
        "name": "camunda:asyncBefore"
      }
    }
  ],
  "appliesTo": [
    "bpmn:ServiceTask"
  ]
}

ERROR

org.camunda.bpm.engine.ProcessEngineException: ENGINE-09008 Exception while instantiating class 'com.mycompany.MailTaskImpl': ENGINE-09017 Cannot load class 'com.mycompany.MailTaskImpl': com.mycompany.MailTaskImpl
    at org.camunda.bpm.engine.impl.util.EngineUtilLogger.exceptionWhileInstantiatingClass(EngineUtilLogger.java:78)

0 个答案:

没有答案