Author Topic: v17.0 "UML rules do not allow this relationship" - Why?  (Read 6881 times)

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8596
  • Karma: +256/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
v17.0 "UML rules do not allow this relationship" - Why?
« on: September 29, 2024, 06:33:46 pm »

As I mentioned previously, we have an Add-In that creates composite diagrams (we call them "Neighborhood Diagrams") for various elements in the repository - automatically drawing ALL the element's linkages with others. In addition, we have implemented scripting to manage visual embedding, automatically creating the appropriate meronymic relationships from the embedded elements to the holonym. We often use Boundary elements as the Holonym.

Accordingly, we have created neighborhood diagrams for notes and boundaries with connections to them.  We haven't made new boundaries of this type for a while, so imagine our surprise when the Add-In failed with the message "UML rules do not allow this relationship"!  Eventually, getting out the Visual Studio compiler and debugging the code, we found the exception was generated by setting the ParentID of the Diagram Note Element (Title Block) of the newly created Neighborhood Diagram to the Element ID of the Boundary Element.  This is usual practice for our Neighborhood diagrams - the diagram and the Diagram Note Element normally sit under the Element being diagrammed.

It's a long time since I delved into the innards of UML 2.5, but I don't recall such a rule (especially since UML has NO notion of a Diagram Element Note). Can anyone enlighten me?

In addition, we found that the issue occurs only when the Diagram and the Diagram Element Note are initially created.

The Integrity Checker makes no complaint, but that's not surprising.

Paolo
Inconsistently correct systems DON'T EXIST!
... Therefore, aim for consistency; in the expectation of achieving correctness....
-Semantica-
Helsinki Principle Rules!

Elpis

  • EA User
  • **
  • Posts: 42
  • Karma: +6/-0
  • Make MDA/MBSE vital.
    • View Profile
Re: v17.0 "UML rules do not allow this relationship" - Why?
« Reply #1 on: October 17, 2024, 08:22:09 pm »
As EA refers to "UML rules" in the error message, question arise: What UML (meta)class is a Boundary (or Note) element instance of (according to EA - AFAIK none of this is UML concepts)?

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13274
  • Karma: +556/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: v17.0 "UML rules do not allow this relationship" - Why?
« Reply #2 on: October 17, 2024, 08:51:05 pm »
As EA refers to "UML rules" in the error message, question arise: What UML (meta)class is a Boundary (or Note) element instance of (according to EA - AFAIK none of this is UML concepts)?
A note is a UML comment.

I don't think boundaries are defined in UML.

On the other hand, EA also refers to UML rules when it comes to BPMN or Archimate rules. They probably mean "metamodel rules" or something more generic than UML.

Geert

ea0522

  • EA User
  • **
  • Posts: 134
  • Karma: +5/-0
    • View Profile
Re: v17.0 "UML rules do not allow this relationship" - Why?
« Reply #3 on: October 17, 2024, 10:56:33 pm »
Reading this, two things come to mind:
  • Since previous versions, the location of notes is changed from under the package to a sub-package without a name. Might have impact on the definition and/or usage of the ParentID.
  • You state it occurs for initially newly created elements. Are they Updated to the repository? Did you do a Refresh of the collections the items belong to?

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13274
  • Karma: +556/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: v17.0 "UML rules do not allow this relationship" - Why?
« Reply #4 on: October 18, 2024, 12:27:55 am »
Reading this, two things come to mind:
  • Since previous versions, the location of notes is changed from under the package to a sub-package without a name. Might have impact on the definition and/or usage of the ParentID.
That is purely a visual change in the user interface. The data has not been changed.

Geert[/list]

Modesto Vega

  • EA Practitioner
  • ***
  • Posts: 1084
  • Karma: +28/-8
    • View Profile
Re: v17.0 "UML rules do not allow this relationship" - Why?
« Reply #5 on: October 18, 2024, 04:17:10 am »
As EA refers to "UML rules" in the error message, question arise: What UML (meta)class is a Boundary (or Note) element instance of (according to EA - AFAIK none of this is UML concepts)?
A note is a UML comment.

I don't think boundaries are defined in UML.

On the other hand, EA also refers to UML rules when it comes to BPMN or Archimate rules. They probably mean "metamodel rules" or something more generic than UML.

Geert

Sparx EA claims to be using UML as its basis which means 2 things:
1) Everything needs to be translated to UML, directly or indirectly, and
2) If something cannot be directly translated, and approximation, hopefully the best one needs to be found.