Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1086922

Summary: Position of annotations not saved
Product: [Retired] JBoss BPMS Platform 6 Reporter: Phil Simpson <psimpson>
Component: jBPM DesignerAssignee: Tihomir Surdilovic <tsurdilo>
Status: CLOSED CURRENTRELEASE QA Contact: Marek Baluch <mbaluch>
Severity: high Docs Contact:
Priority: high    
Version: 6.0.1CC: kverlaen, rrajasek, rzhang
Target Milestone: CR1   
Target Release: 6.0.2   
Hardware: x86_64   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-08-06 19:50:44 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Before
none
After
none
BPMN2 file none

Description Phil Simpson 2014-04-11 20:15:32 UTC
Created attachment 885561 [details]
Before

Description of problem:
The position of text annotations on a process diagram is not preserved during save.

Version-Release number of selected component (if applicable):


How reproducible:
always

Steps to Reproduce:
1. Create a text annotation (attachment "Before")
2.  Save the diagram
3. Reopen the diagram

Actual results:
Annotation is displayed in a different location (attachment "after")

Expected results:
Annotation should not have moved.

Additional info:

Comment 1 Phil Simpson 2014-04-11 20:16:11 UTC
Created attachment 885562 [details]
After

Comment 3 Tihomir Surdilovic 2014-04-22 13:44:00 UTC
Lanes should not contain Artifacts (like text annotations). You can however have a subprocess that contains Artifacts inside a lane. I have tested with Lanes which contain nodes connected to Artifacts and the positioning worked fine. I cannot fully tell from the screenshots what the double lines are around your nodes (sub-lanes are not currently allowed in designer). Please retest with latest fixes and if issue still persists provide the full bpmn2 instead of partial screenshots so we can test.

fix in designer master and 6.0.x branches

Comment 4 Phil Simpson 2014-04-22 14:07:08 UTC
Lanes cannot contain annotations?

This diagram is a reproduction of a widely used standard example, documented here - http://www.omg.org/spec/BPMN/20100601/10-06-02.pdf .  The example has the annotation in a lane.  See also Camunda's interpretation of the diagram here - http://camunda.org/bpmn/tutorial.html . This also has the annotation in a lane.  Most BPMN2 diagrams I have seen have lanes that occupy the entire canvas, as in these two examples, so there is nowhere to place an annotation except in a lane.

Comment 5 Phil Simpson 2014-04-22 14:29:42 UTC
Created attachment 888518 [details]
BPMN2 file

Here's the BPMN2 for the diagram.

Comment 6 Tihomir Surdilovic 2014-04-22 14:34:01 UTC
Thanks for the documents. Swimlanes are container nodes which do not include Artifacts. In the examples you provided I think the pictures show them within. Designer is/was moving these annotations outside the swimlane in your example which I think is OK. I have disabled the inclusion of text annotations within smimlanes to helps users with this.

Comment 7 Tihomir Surdilovic 2014-04-22 14:51:44 UTC
the eclipse.bpmn2 metamodel which we currently use does not allow artifacts within lanes. we can look into changing that at some point to be able to do these types of diagrams.

Comment 8 Phil Simpson 2014-04-22 15:01:03 UTC
Hi Tiho - I'm trying to find where in the BPMN2 spec its says that Artifacts cannot be contained in Lanes.  I can't find any mention of that relative to Annotations, but it does specifically say that Groups can be in lanes and provides an example on p. 69 of a Group spanning multiple Lanes/Pools.  Since Groups are also Artifacts I'm confused as to where this restriction is defined?

Comment 9 Tihomir Surdilovic 2014-04-22 15:55:52 UTC
we use the eclipse.bpmn2 implementation of the spec (https://github.com/eclipse/bpmn2). see :

http://i.imgur.com/RiP53DZ.png
http://i.imgur.com/cGEq10N.png

shows lanes currently cannot contain artifacts, in contrast to subprocesses. 
we can change/update this if we find it is not according to the spec.

Comment 10 Phil Simpson 2014-04-22 19:17:08 UTC
Thanks Tiho.  My opinion, I don't think there's anything wrong with the metamodel.  It's a question of how we interpret the placement of Artifacts on the canvas.

I don't think there's any semantic meaning implied by the placement of a Text Annotation in a Lane, although I am not an expert of course.  In my interpretation, all Annotations are contained by the Process or SubProcess in which they are defined, regardless of where they are positioned on the diagram.  I would argue that placing an annotation in a Lane does not imply that it is contained within that Lane.

If that's correct then I think it's perfectly valid for the modeler to allow annotations to be placed anywhere, and to attach them all to the Process.  I suspect that's what other tools do.

I think that preventing the user from placing an annotation in a lane will be annoying.  It will force annotations to be placed in illogical locations away from the flow objects they are attached to.

Comment 11 Tihomir Surdilovic 2014-04-23 00:26:16 UTC
OK agreed. Connection and inclusion rules in Designer drawing canvas currently follow the eclipse.bpmn2 impl closely. We can add exception and I think this would be a good one.

Comment 12 Tihomir Surdilovic 2014-04-23 00:26:44 UTC
moving back to assigned state

Comment 13 Tihomir Surdilovic 2014-04-23 14:57:24 UTC
added some fixes for this to designer master and 6.0.x branches. please give it a try again and let me know if its better. since i do not have the actual .bpmn2 source of the process here i cannot test fully but have done tests with similar.

Comment 14 Phil Simpson 2014-04-24 13:51:53 UTC
Apparently I don't have access to the branches, but will test the next build if the fix will be in there.  I did upload the .bpmn2 file.  It's attached to this bug.  Thanks!

Comment 15 Tihomir Surdilovic 2014-04-24 14:54:36 UTC
Ok I must have missed it - sorry. Tested with the attached bpmn2 and the text annotation stays in place :) Let me know if any issues come up.

Comment 18 Rajesh Rajasekaran 2014-06-04 16:48:36 UTC
Ryan, can you check if this fix made into the product build?

Comment 19 Marek Baluch 2014-06-17 08:04:47 UTC
Verified on 6.0.2.CR1.