Bug 472174 - Event SubProcess may not have incoming or outgoing sequence flows
Summary: Event SubProcess may not have incoming or outgoing sequence flows
Status: REOPENED
Alias: None
Product: BPMN2Modeler
Classification: SOA
Component: UI (show other bugs)
Version: 1.1.3   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: future   Edit
Assignee: Robert Brodt CLA
QA Contact: Jozef Marko CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-07-08 09:48 EDT by Robert Brodt CLA
Modified: 2016-04-18 02:13 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Robert Brodt CLA 2015-07-08 09:48:34 EDT
Sequence flow connections to/from an Event SubProcess should not be allowed. If a normal, embedded SubProcess is converted to an Event SubProcess, all incoming and outgoing connections should be removed.
Comment 1 Robert Brodt CLA 2015-07-09 11:29:41 EDT
Fixed.
Comment 2 Jozef Marko CLA 2016-02-01 04:36:19 EST
"Embedded SubProcess" and "Multiple Instance SubProcess" can't be converted to "Event SubProcess".

Other subprocesses can be converted but incoming and outgoing connections are not removed.
Comment 3 Jozef Marko CLA 2016-04-11 04:27:58 EDT
Bob, please follow these steps:
1. create any task in process
2. create ad-hoc subprocess in the same process
3. connect elements from steps 1. and 2.
4. morph subprocess from step 2. to event subprocess
5. state, when event subprocess has incoming sequence flow

Reproduced on:
jbds-9.1.0.CR1_jbdsis-9.0.0.CR1
jbtis-4.3.0.CR1
BPMN2 Modeler - 1.2.4.Final-v20160330-1625-B110
Comment 4 Jozef Marko CLA 2016-04-13 02:01:36 EDT
See the previous comment.
Comment 5 Robert Brodt CLA 2016-04-14 12:53:52 EDT
This use case is unusual. An "Event SubProcess" is really the same object as an "Embedded SubProcess" except that it has the "Triggered by Event" attribute set. The "Event SubProcess" tool palette item is only provided as a convenience, since the end effect of creating an Embedded SubProcess and then checking the "Triggered by Event" checkbox is the same.

The same goes for the "Multiple Instances SubProcess" - the only thing the tool palette action does differently is to set the Embedded SubProcess Loop Characteristics to "Multi-Instance".

The "Morph" feature is implemented in such a way that it only allows you to change the object to a different type than what it already is. It doesn't make sense, for example, to morph a User Task to a User Task - that's a no-op. That's why, for example, "Embedded SubProcess", "Event SubProcess" and "Multiple Instances" (which are all the same type of BPMN2 object) do not show up in the list of available "morph to" selections for a SubProcess. On the other hand, "AdHoc SubProcess" and "Reusable SubProcess" (CallActivity) are subclasses of SubProcess, and therefore different types - these CAN be morphed to one of the SubProcess types in the tool palette.

These "convenience items" (Event SubProcess, Multiple Instance SubProcess, etc.) are implemented as macros in the tool palette and the tool palette handler has no way of recognizing what distinguishes an "Embedded SubProcess" from an "Event SubProcess"; as far as it is concerned, they are both the same type of object and therefore you can't morph from one to the other.

To fix these problems (removing sequence flows when morphing to an Event SubProcess and allowing the ability to morph from one type of SubProcess to another) will require some serious work - I'm not sure  it's worth the effort.

You did notice (I hope) that when you start with a "normal" Embedded SubProcess that has incoming and outgoing sequence flows, and then click the "Triggered by Event" checkbox, that the connections are removed. That was the original (and only) use case that was addressed by this bug fix.

I'll leave it up to you guys to prioritize this bug...
Comment 6 Jozef Marko CLA 2016-04-18 02:13:28 EDT
Bob, thanks for morphing explanation. Morphing feature is present also in web designer. But there is not this feature so smart as in bpmn2 modeler. I am fine if in bpmn2 modeler will be possibility to morph only to "really" different kinds of elements.

To the second point. Either it is described morphing unusual or it is executed by a mistake, in both cases incoming and outgoing connections should be removed as they are removed if is checkbox 'Triggered by event' in embedded subprocess checked. Of course it has no the highest priority but I prefer to keep this issue open.