3
votes

I'm using BPMN2 modeler v1.1.3.201503101616 in Eclipse Luna, developing for JBPM 6.0.3 for Jboss EAP 6.1. Any time I add a signal boundary event to an activity, it's flagged with the error "Data Output Signal_1_Output () has no Data Type". The error has the type "jBPM Process Problem".

For example, here's a simple workflow that I put together:

process with signal boundary event

And here's the generated source for the process (the line with the error is marked):

  <bpmn2:itemDefinition id="ItemDefinition_4" isCollection="false" structureRef="String"/>
  <bpmn2:signal id="SignalFoo" name="SignalFoo"/>
  <bpmn2:process id="defaultPackage.Scratch" tns:packageName="defaultPackage" name="Scratch" isExecutable="true" processType="Private">
    <bpmn2:property id="str" itemSubjectRef="ItemDefinition_4" name="str"/>
    <bpmn2:startEvent id="StartEvent_1" name="StartProcess">
      <bpmn2:outgoing>SequenceFlow_1</bpmn2:outgoing>
    </bpmn2:startEvent>
    <bpmn2:scriptTask id="ScriptTask_1" name="Script Task 1" scriptFormat="http://www.java.com/java">
      <bpmn2:incoming>SequenceFlow_1</bpmn2:incoming>
      <bpmn2:outgoing>SequenceFlow_2</bpmn2:outgoing>
      <bpmn2:script>System.out.println(&quot;Hello world!&quot;);</bpmn2:script>
    </bpmn2:scriptTask>
    <bpmn2:sequenceFlow id="SequenceFlow_1" tns:priority="1" sourceRef="StartEvent_1" targetRef="ScriptTask_1"/>
    <bpmn2:boundaryEvent id="BoundaryEvent_1" name="" attachedToRef="ScriptTask_1">
      <bpmn2:outgoing>SequenceFlow_3</bpmn2:outgoing>
      <bpmn2:dataOutput id="DataOutput_1" name="Signal_1_Output"/> <-- Error
      <bpmn2:dataOutputAssociation id="DataOutputAssociation_1">
        <bpmn2:sourceRef>DataOutput_1</bpmn2:sourceRef>
        <bpmn2:targetRef>str</bpmn2:targetRef>
      </bpmn2:dataOutputAssociation>
      <bpmn2:outputSet id="OutputSet_1" name="Output Set 1">
        <bpmn2:dataOutputRefs>DataOutput_1</bpmn2:dataOutputRefs>
      </bpmn2:outputSet>
      <bpmn2:signalEventDefinition id="SignalEventDefinition_1" signalRef="SignalFoo"/>
    </bpmn2:boundaryEvent>
    <bpmn2:endEvent id="EndEvent_1" name="End Event 1">
      <bpmn2:incoming>SequenceFlow_2</bpmn2:incoming>
    </bpmn2:endEvent>
    <bpmn2:sequenceFlow id="SequenceFlow_2" tns:priority="1" sourceRef="ScriptTask_1" targetRef="EndEvent_1"/>
    <bpmn2:scriptTask id="ScriptTask_2" name="Script Task 2" scriptFormat="http://www.java.com/java">
      <bpmn2:incoming>SequenceFlow_3</bpmn2:incoming>
      <bpmn2:outgoing>SequenceFlow_4</bpmn2:outgoing>
      <bpmn2:script>System.out.println(&quot;Goodbye, cruel world!&quot;);</bpmn2:script>
    </bpmn2:scriptTask>
    <bpmn2:sequenceFlow id="SequenceFlow_3" tns:priority="1" sourceRef="BoundaryEvent_1" targetRef="ScriptTask_2"/>
    <bpmn2:endEvent id="EndEvent_2" name="End Event 2">
      <bpmn2:incoming>SequenceFlow_4</bpmn2:incoming>
    </bpmn2:endEvent>
    <bpmn2:sequenceFlow id="SequenceFlow_4" tns:priority="1" sourceRef="ScriptTask_2" targetRef="EndEvent_2"/>
  </bpmn2:process>

Despite the error, Jbpm is able to run the process without complaint, and the boundary event seems to work correctly. I haven't been able to find any other mention of this specific error on the Internet. I've also looked for ways to adjust the validator for jBPM processes, but I can't find anything about it in the eclipse preferences.

Is this a legitimate error? Can someone suggest how to fix it? Alternately, is there a way to disable this validation rule?

2

2 Answers

4
votes

jBPM doesn't have the requirement to specify a datatype (for boundary events and other places). The Modeler is incorrectly flagging this as an error. Could you open a Eclipse BPMN2 Modeler Bugzilla possibly so we can fix this if it hasn't already?

3
votes

I opened https://bugs.eclipse.org/bugs/show_bug.cgi?id=463362 for the issue.

The workaround is to open the bpmn file in the XML editor and modify the dataOutput element:

<bpmn2:dataOutput id="DataOutput_1" name="Signal_1_Output"/>

Add an attribute named "itemSubjectRef" referencing an appropriate itemDefinition from the beginning of the file, for example:

<bpmn2:dataOutput id="DataOutput_1"
 itemSubjectRef="ItemDefinition_4" name="Signal_1_Output"/>

This stops BPMN2 from flagging the event as an error. I haven't found a way to make this change from within the BPMN2 modeler editor.

Update:

Bug 463362 is marked as fixed in BPMN Modeler 1.1.4 and 1.2.0.