Author Topic: clarify intended practice for relating elements  (Read 9490 times)

bockfu

  • EA User
  • **
  • Posts: 55
  • Karma: +4/-1
    • View Profile
clarify intended practice for relating elements
« on: November 01, 2015, 04:43:10 pm »
what is the intended practice for modeling different perspectives of the same entity?  

For example, what I have done is define a UML class element and specify associations and attributes.   Then if I want to show its connections to other elements, create an UML Component diagram.   Again, add provides/requires interface and other connections.

I would think there should be a way to associate the two elements if they are modeling the same entity.   The rationale is to have consistent names, reconcile and leverage each elements associations and attributes.    I haven't come across a way to do this.  

Anyone have pointers here?  

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13387
  • Karma: +566/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: clarify intended practice for relating element
« Reply #1 on: November 02, 2015, 03:54:05 pm »
If you have two elements representing the same thing than you have one too many.

You should only ever have one element to represent one (aspect of a) thing.

Geert

bockfu

  • EA User
  • **
  • Posts: 55
  • Karma: +4/-1
    • View Profile
Re: clarify intended practice for relating element
« Reply #2 on: November 04, 2015, 05:41:07 am »
Geert - I concur.  I am trying to learn what the common practice is when modeling a system.  

Contrasting your response to the example shared here
http://stackoverflow.com/questions/17390049/component-diagram-versus-class-diagram, I'll infer that the model shall avoid duplicate elements of different types.  Class elements may relate to component elements, but they are different elements, and used to model different structural aspects of the system.





qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +396/-301
  • I'm no guru at all
    • View Profile
Re: clarify intended practice for relating element
« Reply #3 on: November 04, 2015, 08:04:03 am »
Despite the title the upper diagram is not a component diagram but a set of notes.

q.

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8083
  • Karma: +118/-20
    • View Profile
Re: clarify intended practice for relating element
« Reply #4 on: November 04, 2015, 08:46:15 am »
Quote
If you have two elements representing the same thing than you have one too many.

You should only ever have one element to represent one (aspect of a) thing.
The UML specification disagrees with you on this and defines the Trace connector for this situation.
Quote
Specifies a trace relationship between model elements or sets of model elements that represent the same concept in different models. Traces are mainly used for tracking requirements and changes across models. As model changes can occur in both directions, the directionality of the dependency can often be ignored. The mapping specifies the relationship between the two, but it is rarely computable and is usually informal.
It's still preferable to avoid if possible, but there are circumstances where it is appropriate.
« Last Edit: November 04, 2015, 08:47:46 am by simonm »

Glassboy

  • EA Practitioner
  • ***
  • Posts: 1367
  • Karma: +112/-75
    • View Profile
Re: clarify intended practice for relating element
« Reply #5 on: November 04, 2015, 09:13:49 am »
Quote
Despite the title the upper diagram is not a component diagram but a set of notes.

q.

I agree, that's a horrible example.

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +396/-301
  • I'm no guru at all
    • View Profile
Re: clarify intended practice for relating element
« Reply #6 on: November 04, 2015, 09:40:48 am »
@Simon: It say "same concept in different models". But here we have one model (aka repository). And inside one model there is only one representation of a concept. Else it would be ambiguous or contradicting.

q.
« Last Edit: November 04, 2015, 09:41:27 am by qwerty »

Glassboy

  • EA Practitioner
  • ***
  • Posts: 1367
  • Karma: +112/-75
    • View Profile
Re: clarify intended practice for relating element
« Reply #7 on: November 04, 2015, 11:30:54 am »
You can have multiple models in one repository.  

The usefulness of your model will be severally hampered if everyone starts "borrowing" one of your elements and using it elsewhere, rather than copying it and tracing back to it.  Imagine the garbage a project that fails could create in an otherwise good reflection of reality :-)

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8607
  • Karma: +257/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: clarify intended practice for relating element
« Reply #8 on: November 04, 2015, 03:09:15 pm »
Quote
You can have multiple models in one repository.  

The usefulness of your model will be severally hampered if everyone starts "borrowing" one of your elements and using it elsewhere, rather than copying it and tracing back to it.  Imagine the garbage a project that fails could create in an otherwise good reflection of reality :-)
Well if the model is a "good reflection of reality", then it should survive the project failure.

When you are building a common repository, you want people to "borrow" the common item.  But you also need to control changes to the common item.  We've implemented the notion of doppelgangers which are duplicates of the common item in each project and we control how changes at either end are disseminated.  Technically, you can argue that they are «traces», but it is much stronger than that.  Automation keeps things in line behind the scenes.

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

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13387
  • Karma: +566/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: clarify intended practice for relating element
« Reply #9 on: November 04, 2015, 03:34:25 pm »
Quote
Quote
If you have two elements representing the same thing than you have one too many.

You should only ever have one element to represent one (aspect of a) thing.
The UML specification disagrees with you on this and defines the Trace connector for this situation.
Quote
Specifies a trace relationship between model elements or sets of model elements that represent the same concept in different models. Traces are mainly used for tracking requirements and changes across models. As model changes can occur in both directions, the directionality of the dependency can often be ignored. The mapping specifies the relationship between the two, but it is rarely computable and is usually informal.
It's still preferable to avoid if possible, but there are circumstances where it is appropriate.
Simon,

It's not because you CAN that you SHOULD.

I was not stating that it was against UML syntax, I was merely stating a best practice.

Geert

bockfu

  • EA User
  • **
  • Posts: 55
  • Karma: +4/-1
    • View Profile
Re: clarify intended practice for relating element
« Reply #10 on: November 04, 2015, 05:45:59 pm »
my original question has been answered, thank you all for the dialog.  Here is a summary as I see it:

  • The trace association can be used to relate elements to one another.  Rationale from OMG UML spec Traces are mainly used for tracking requirements and changes across models.
  • Multiple elements modeling the same entity should be avoided.  Rationale is the different element types are intended to model different aspects of the system.  The intention of the model can be unclear and have added complexity if two elements are representing the same thing.

Background
I have been using EA for several years, but rarely in a multi-user usage model.  A team of us will start using a common model and I am investigating what guard rails we should apply for how we work.

I found I had used class diagrams to illustrate the types of widgets via specialization/generalization, and component diagrams for how the widgets interface with one another.    This didn't seem right and I wanted to get input from other UML practitioners.



bockfu

  • EA User
  • **
  • Posts: 55
  • Karma: +4/-1
    • View Profile
Re: clarify intended practice for relating element
« Reply #11 on: November 04, 2015, 05:58:54 pm »
Quote
Quote
Despite the title the upper diagram is not a component diagram but a set of notes.

q.

I agree, that's a horrible example.

This example from OMG UML spec 2.5 (document number formal/15-03-01) is both more illustrative then the first example and better representation of what might be found in a component diagram.

« Last Edit: November 04, 2015, 06:03:54 pm by bockfu »

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13387
  • Karma: +566/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: clarify intended practice for relating element
« Reply #12 on: November 04, 2015, 07:01:40 pm »
I think you should not read too much in the type of diagram.
Whether you call it a component diagram, or a class diagram really doesn't play a role.

What does play is what you show on those diagrams. In the example from the UML specs above it is still only showing classes and interfaces.

Geert

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +396/-301
  • I'm no guru at all
    • View Profile

Glassboy

  • EA Practitioner
  • ***
  • Posts: 1367
  • Karma: +112/-75
    • View Profile
Re: clarify intended practice for relating element
« Reply #14 on: November 05, 2015, 08:32:42 am »
Quote
Quote
You can have multiple models in one repository.  

The usefulness of your model will be severally hampered if everyone starts "borrowing" one of your elements and using it elsewhere, rather than copying it and tracing back to it.  Imagine the garbage a project that fails could create in an otherwise good reflection of reality :-)
Well if the model is a "good reflection of reality", then it should survive the project failure.

When you are building a common repository, you want people to "borrow" the common item.  But you also need to control changes to the common item.  We've implemented the notion of doppelgangers which are duplicates of the common item in each project and we control how changes at either end are disseminated.  Technically, you can argue that they are «traces», but it is much stronger than that.  Automation keeps things in line behind the scenes.

Paolo

Well let me phrase, you want someone to borrow you don't want them to steal or convert.  You also don't want anything that you use that element for to be suddenly broken.  In EA any documentation that uses connectors is generally the first thing to suffer.