AnsweredAssumed Answered

bpmn.xml Deployment fails

Question asked by xiangyuely on Jul 26, 2012
Latest reply on Jul 27, 2012 by frederikheremans1
Hi,
  i deploy a simple process and add a listenter to a user task,but I got this error message:
org.activiti.engine.ActivitiException: cvc-complex-type.2.4.a: Invalid content was found starting with element 'extensionElements'. One of '{"http://www.omg.org/spec/BPMN/20100524/MODEL':resourceRole, "http://www.omg.org/spec/BPMN/20100524/MODEL':loopCharacteristics, "http://www.omg.org/spec/BPMN/20100524/MODEL':rendering}' is expected. | cn/sec/ac/askForLeaveParallel.bpmn20.xml | line 30 | column 24
   at org.activiti.engine.impl.util.xml.Parse.throwActivitiExceptionForErrors(Parse.java:186)
   at org.activiti.engine.impl.bpmn.parser.BpmnParse.execute(BpmnParse.java:222)
   at org.activiti.engine.impl.bpmn.deployer.BpmnDeployer.deploy(BpmnDeployer.java:86)
   at org.activiti.engine.impl.persistence.deploy.DeploymentCache.deploy(DeploymentCache.java:38)
   at org.activiti.engine.impl.persistence.entity.DeploymentManager.insertDeployment(DeploymentManager.java:42)
   at org.activiti.engine.impl.cmd.DeployCmd.execute(DeployCmd.java:58)
   at org.activiti.engine.impl.cmd.DeployCmd.execute(DeployCmd.java:30)
   at org.activiti.engine.impl.interceptor.CommandExecutorImpl.execute(CommandExecutorImpl.java:24)
   at org.activiti.engine.impl.interceptor.CommandContextInterceptor.execute(CommandContextInterceptor.java:42)
   at org.activiti.spring.SpringTransactionInterceptor$1.doInTransaction(SpringTransactionInterceptor.java:42)
   at org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:130)
   at org.activiti.spring.SpringTransactionInterceptor.execute(SpringTransactionInterceptor.java:40)
   at org.activiti.engine.impl.interceptor.LogInterceptor.execute(LogInterceptor.java:33)
   at org.activiti.engine.impl.RepositoryServiceImpl.deploy(RepositoryServiceImpl.java:46)
   at org.activiti.engine.impl.repository.DeploymentBuilderImpl.deploy(DeploymentBuilderImpl.java:106)
   at cn.sec.ac.ProcessEngineAskForLeaveParallel.main(ProcessEngineAskForLeaveParallel.java:27)


xml code:
<?xml version="1.0" encoding="UTF-8"?>
<definitions xmlns="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:activiti="http://activiti.org/bpmn" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:omgdc="http://www.omg.org/spec/DD/20100524/DC" xmlns:omgdi="http://www.omg.org/spec/DD/20100524/DI" typeLanguage="http://www.w3.org/2001/XMLSchema" expressionLanguage="http://www.w3.org/1999/XPath" targetNamespace="http://www.activiti.org/test">
   <process id="askForLeaveParallel">
      <startEvent id="askForLeaveParallelStartEvent" name="请假流程开始事件">
         <outgoing>sid-01BF60CD-36AF-4987-9828-0048F23ED881</outgoing>
      </startEvent>
      <parallelGateway gatewayDirection="Diverging" id="askForLeaveParallelDiverging" name="请假流程并行网关分支">
         <incoming>sid-01BF60CD-36AF-4987-9828-0048F23ED881</incoming>
         <outgoing>sid-F58C601A-7C01-4A09-A355-2855E0164DB2</outgoing>
         <outgoing>sid-345D8821-50FB-4DDB-B124-74AA93500D3F</outgoing>
      </parallelGateway>
      <userTask id="baseManagerApprove" name="基层经理审批">
        <humanPerformer>
           <resourceAssignmentExpression>
              <formalExpression>fozzie</formalExpression>
           </resourceAssignmentExpression>
        </humanPerformer>     
      </userTask>
      <parallelGateway gatewayDirection="Converging" id="askForLeaveParallelConverging" name="请假流程并行网关聚合">
         <incoming>sid-3EA71564-416E-4462-8F3B-3AF3CE5E3A4C</incoming>
         <incoming>sid-8411F1E6-BD66-45B9-B37C-2CFEB2DDBDE6</incoming>
         <outgoing>sid-AAAA3713-F914-4B68-B29B-E538CA04CB3B</outgoing>
      </parallelGateway>
      <userTask id="departManagerApprove" name="部门经理审批">
         <humanPerformer>
           <resourceAssignmentExpression>
              <formalExpression>kermit</formalExpression>
           </resourceAssignmentExpression>
        </humanPerformer>
        <extensionElements>
         <activiti:executionListener class="cn.sec.ac.ExecutionListenerNotify" event="end"></activiti:executionListener>        
        </extensionElements>
      </userTask>
      <userTask id="humanApprove" name="人力审批">
         <humanPerformer>
           <resourceAssignmentExpression>
              <formalExpression>gonzo</formalExpression>
           </resourceAssignmentExpression>
        </humanPerformer>     
      </userTask>
      <endEvent id="askForLeaveParallelEndEvent" name="请假流程结束事件">
         <incoming>sid-C847296F-B68A-438B-8A93-3DA481D9D389</incoming>
      </endEvent>
      <sequenceFlow id="sid-3EA71564-416E-4462-8F3B-3AF3CE5E3A4C" name="" sourceRef="departManagerApprove" targetRef="askForLeaveParallelConverging"/>
      <sequenceFlow id="sid-8411F1E6-BD66-45B9-B37C-2CFEB2DDBDE6" name="" sourceRef="baseManagerApprove" targetRef="askForLeaveParallelConverging"/>
      <sequenceFlow id="sid-AAAA3713-F914-4B68-B29B-E538CA04CB3B" name="" sourceRef="askForLeaveParallelConverging" targetRef="humanApprove"/>
      <sequenceFlow id="sid-C847296F-B68A-438B-8A93-3DA481D9D389" name="" sourceRef="humanApprove" targetRef="askForLeaveParallelEndEvent"/>
      <sequenceFlow id="sid-01BF60CD-36AF-4987-9828-0048F23ED881" name="" sourceRef="askForLeaveParallelStartEvent" targetRef="askForLeaveParallelDiverging"/>
      <sequenceFlow id="sid-F58C601A-7C01-4A09-A355-2855E0164DB2" name="" sourceRef="askForLeaveParallelDiverging" targetRef="baseManagerApprove">
      </sequenceFlow>
      <sequenceFlow id="sid-345D8821-50FB-4DDB-B124-74AA93500D3F" name="" sourceRef="askForLeaveParallelDiverging" targetRef="departManagerApprove">
      </sequenceFlow>
   </process>
</definitions>

Why do i get this error?The class exists, it is a default class of the activiti-engine-examples and is described in the user guide.

thanks a lot for help

Outcomes