Cannot deploy process with id containing space
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-09-2011 04:38 AM
Hi,
I am using the Activiti Engine v5.5 and I noticed that I cannot deploy a process that has an id that contains a space.
Here is the error message:
Here is my testSignavioResult.bpmn20.xml:
If I remove the space, as in these 2 lines:
From:
From:
then, the process will be able to be deployed.
Is there a special reason for not allowing a space in process id? Or is it just a bug?
I am using the Activiti Engine v5.5 and I noticed that I cannot deploy a process that has an id that contains a space.
Here is the error message:
May 9, 2011 4:27:13 PM org.activiti.engine.impl.ProcessEngineImpl <init>INFO: ProcessEngine default createdMay 9, 2011 4:27:13 PM org.activiti.engine.impl.bpmn.deployer.BpmnDeployer deployINFO: Processing resource testSignavioResult.bpmn20.xmlMay 9, 2011 4:27:13 PM org.activiti.engine.impl.bpmn.parser.BpmnParse parseDefinitionsAttributesINFO: XMLSchema currently not supported as typeLanguageMay 9, 2011 4:27:13 PM org.activiti.engine.impl.bpmn.parser.BpmnParse parseDefinitionsAttributesINFO: XPath currently not supported as expressionLanguageMay 9, 2011 4:27:13 PM org.activiti.engine.impl.interceptor.CommandContext closeSEVERE: Error while closing command contextorg.activiti.engine.ActivitiException: cvc-datatype-valid.1.2.1: 'testServiceTask Key' is not a valid value for 'NCName'. | testSignavioResult.bpmn20.xml | line 3 | column 86cvc-attribute.3: The value 'testServiceTask Key' of attribute 'id' on element 'process' is not valid with respect to its type, 'ID'. | testSignavioResult.bpmn20.xml | line 3 | column 86cvc-datatype-valid.1.2.1: 'testServiceTask Key' is not a valid value for 'QName'. | testSignavioResult.bpmn20.xml | line 26 | column 105cvc-attribute.3: The value 'testServiceTask Key' of attribute 'bpmnElement' on element 'bpmndi:BPMNPlane' is not valid with respect to its type, 'QName'. | testSignavioResult.bpmn20.xml | line 26 | column 105 at org.activiti.engine.impl.util.xml.Parse.throwActivitiExceptionForErrors(Parse.java:186) at org.activiti.engine.impl.bpmn.parser.BpmnParse.execute(BpmnParse.java:172) at org.activiti.engine.impl.bpmn.deployer.BpmnDeployer.deploy(BpmnDeployer.java:81) at org.activiti.engine.impl.persistence.deploy.DeploymentCache.deploy(DeploymentCache.java:37) at org.activiti.engine.impl.persistence.entity.DeploymentManager.insertDeployment(DeploymentManager.java:39) at org.activiti.engine.impl.cmd.DeployCmd.execute(DeployCmd.java:57) 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:43) at org.activiti.engine.impl.repository.DeploymentBuilderImpl.deploy(DeploymentBuilderImpl.java:105) at testActiviti.App.main(App.java:26) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.codehaus.mojo.exec.ExecJavaMojo$1.run(ExecJavaMojo.java:290) at java.lang.Thread.run(Thread.java:619)
Here is my testSignavioResult.bpmn20.xml:
<?xml version="1.0" encoding="UTF-8"?><definitions xmlns="http://www.omg.org/spec/BPMN/20100524/MODEL" 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" xmlns:signavio="http://www.signavio.com" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" exporter="Signavio Process Editor, http://www.signavio.com" exporterVersion="" id="sid-660c3ba3-4e73-4b77-891d-12ac6570bf7c" targetNamespace="http://www.signavio.com/bpmn20" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL http://www.omg.org/spec/BPMN/2.0/20100501/BPMN20.xsd"> <process id="testServiceTask Key" isExecutable="false" name="testServiceTaskName"> <startEvent id="sid-C3606459-DAF0-4878-B0D9-617D3F4B4BFD" name=""> <extensionElements> <signavio:signavioMetaData metaKey="bgcolor" metaValue="#ffffff"/> </extensionElements> </startEvent> <serviceTask activiti:class="testActiviti.ServiceDelegate" id="sid-E380ED68-3FE7-4989-99C7-F2E8FB251A07" isForCompensation="false" name="Task name"> <extensionElements> <activiti:field expression="serviceName" name="serviceName"/> <activiti:field expression="serviceInputVariables" name="serviceInputVar"/> <activiti:field expression="serviceOutputVariables" name="serviceOutputVar"/> <signavio:signavioMetaData metaKey="bgcolor" metaValue="#ffffcc"/> </extensionElements> </serviceTask> <endEvent id="sid-D3183BEA-DC44-4AC5-A5F7-C4C135BA8009" name=""> <extensionElements> <signavio:signavioMetaData metaKey="bgcolor" metaValue="#ffffff"/> </extensionElements> </endEvent> <sequenceFlow id="sid-6EB4D5AB-B57E-44E0-817B-B40F27EEDF5D" name="" sourceRef="sid-C3606459-DAF0-4878-B0D9-617D3F4B4BFD" targetRef="sid-E380ED68-3FE7-4989-99C7-F2E8FB251A07"/> <sequenceFlow id="sid-FC81BE2C-B23F-4E88-BA95-BF2676F2EE76" name="" sourceRef="sid-E380ED68-3FE7-4989-99C7-F2E8FB251A07" targetRef="sid-D3183BEA-DC44-4AC5-A5F7-C4C135BA8009"/> </process> <bpmndi:BPMNDiagram id="sid-046b0014-c5e3-4bac-9353-54af0edf4fb1"> <bpmndi:BPMNPlane bpmnElement="testServiceTask Key" id="sid-404da466-7bc8-4467-b98e-7e1fca88dbbb"> <bpmndi:BPMNShape bpmnElement="sid-C3606459-DAF0-4878-B0D9-617D3F4B4BFD" id="sid-C3606459-DAF0-4878-B0D9-617D3F4B4BFD_gui"> <omgdc:Bounds height="30.0" width="30.0" x="75.0" y="176.0"/> </bpmndi:BPMNShape> <bpmndi:BPMNShape bpmnElement="sid-E380ED68-3FE7-4989-99C7-F2E8FB251A07" id="sid-E380ED68-3FE7-4989-99C7-F2E8FB251A07_gui"> <omgdc:Bounds height="80.0" width="100.0" x="150.0" y="151.0"/> </bpmndi:BPMNShape> <bpmndi:BPMNShape bpmnElement="sid-D3183BEA-DC44-4AC5-A5F7-C4C135BA8009" id="sid-D3183BEA-DC44-4AC5-A5F7-C4C135BA8009_gui"> <omgdc:Bounds height="28.0" width="28.0" x="285.0" y="177.0"/> </bpmndi:BPMNShape> <bpmndi:BPMNEdge bpmnElement="sid-FC81BE2C-B23F-4E88-BA95-BF2676F2EE76" id="sid-FC81BE2C-B23F-4E88-BA95-BF2676F2EE76_gui"> <omgdi:waypoint x="250.0" y="191.0"/> <omgdi:waypoint x="285.0" y="191.0"/> </bpmndi:BPMNEdge> <bpmndi:BPMNEdge bpmnElement="sid-6EB4D5AB-B57E-44E0-817B-B40F27EEDF5D" id="sid-6EB4D5AB-B57E-44E0-817B-B40F27EEDF5D_gui"> <omgdi:waypoint x="105.0" y="191.0"/> <omgdi:waypoint x="150.0" y="191.0"/> </bpmndi:BPMNEdge> </bpmndi:BPMNPlane> </bpmndi:BPMNDiagram></definitions>
If I remove the space, as in these 2 lines:
From:
<process id="testServiceTask Key" isExecutable="false" name="testServiceTaskName">
To:<process id="testServiceTaskKey" isExecutable="false" name="testServiceTaskName">
From:
<bpmndi:BPMNPlane bpmnElement="testServiceTask Key" id="sid-404da466-7bc8-4467-b98e-7e1fca88dbbb">
To:<bpmndi:BPMNPlane bpmnElement="testServiceTaskKey" id="sid-404da466-7bc8-4467-b98e-7e1fca88dbbb">
then, the process will be able to be deployed.
Is there a special reason for not allowing a space in process id? Or is it just a bug?
Labels:
- Labels:
-
Archive
2 REPLIES 2
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-09-2011 05:01 AM
cvc-datatype-valid.1.2.1: 'testServiceTask Key' is not a valid value for 'QName'
The id should be a QName, according to the BPMN 2.0 spec, so no whitespace allowed (and some other characters, like colons etc). So it's not a bug, just a restriction on the value of the id.
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-09-2011 06:41 AM
I see. Thanks for the clarification!
