Book a Demo

Author Topic: GUID integrity  (Read 7136 times)

Bhavesh

  • EA Novice
  • *
  • Posts: 10
  • Karma: +0/-0
    • View Profile
GUID integrity
« on: November 27, 2009, 11:46:34 pm »
Hello guys,

I wanted to confirm about possibility of GUID changing.
What happens when "Strip GUID" is checked?
Could it change during import/export?
Or any other way.

Thank you.

Bhavesh.

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13471
  • Karma: +571/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: GUID integrity
« Reply #1 on: November 28, 2009, 12:14:26 am »
If you import a package with "strip guid" it will assign all new guids to all the imported elements.

Geert

Bhavesh

  • EA Novice
  • *
  • Posts: 10
  • Karma: +0/-0
    • View Profile
Re: GUID integrity
« Reply #2 on: November 28, 2009, 01:16:27 am »
I asked because we're doing something based on this GUID and we've exported/imported tens of packages. But it happened once recently that GUIDs were changed in XMI file.

Is it possible for GUIDs to change when somebody restores EA db backup, works in EA and exports XMI?

Thank you.

Bhavesh.

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13471
  • Karma: +571/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: GUID integrity
« Reply #3 on: November 28, 2009, 01:24:18 am »
I'm pretty sure it can only happen when importing xmi files.

Geert

Bhavesh

  • EA Novice
  • *
  • Posts: 10
  • Karma: +0/-0
    • View Profile
Re: GUID integrity
« Reply #4 on: November 28, 2009, 01:26:19 am »
I wasn't going to start this thread and bother you because it has happend only once.

Thank you for reassuring me.

Thank you.

Bhavesh.

Oliver F.

  • EA User
  • **
  • Posts: 573
  • Karma: +2/-1
  • Aren´t we all in the model business ?
    • View Profile
    • Karl Storz homepage
Re: GUID integrity
« Reply #5 on: November 28, 2009, 02:05:08 am »
To summarize the GUID issue and to add what Geert said:

The GUID is unique across all elements inside a EA project (propably also outside though I have not checked this).
GUIDs never change for an element unless it is deleted and recreated.

Exporting elements also exports the GUIDs, reimporting the elements reimports them with the former GUIDs so that all references to elements are still valid and existing. New elements in the xmi file get new unique GUIDs.

Reimporting the elements with the "strip GUID" option set reimports the elements with new GUIDs (by freshly/redundantly creating those) so references from the former project are not restored.

Oliver

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13471
  • Karma: +571/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: GUID integrity
« Reply #6 on: November 28, 2009, 04:38:18 pm »
Quote
The GUID is unique across all elements inside a EA project (propably also outside though I have not checked this).

Oliver,

By the very nature of a GUID (Globally Unique Identifier) you can expect it to be unique amongst all GUID's ever created.

Theoretical there is of course a chance that two GUID's are created with exactly the same value, but I think that is as likely as me winning the lottery two weeks in a row.

Geert

son-of-sargasso

  • EA User
  • **
  • Posts: 122
  • Karma: +0/-0
    • View Profile
Re: GUID integrity
« Reply #7 on: November 28, 2009, 07:03:41 pm »
Quote
but I think that is as likely as me winning the lottery two weeks in a row.

Actually, theoretically, if the 122 "random" digits in the GUID are truly random then I think you'd have to win a lottery with 50,000 tickets about 8 times in a row.

However, the 122 digits are not truly random and if they use an algorithm that includes the MAC address of the local computer and a single timestamp, then the likelihood of the collision is a lot higher.

But, then again, my problem is winning the lottery one time in a row.   :(

bruce

Oliver F.

  • EA User
  • **
  • Posts: 573
  • Karma: +2/-1
  • Aren´t we all in the model business ?
    • View Profile
    • Karl Storz homepage
Re: GUID integrity
« Reply #8 on: December 01, 2009, 12:10:47 am »
Quote
But, then again, my problem is winning the lottery one time in a row.   :(

I have that very same problem so the chances that one of us is winning the lottery once have at least doubled.

BTW, does it affect propability that I never play such things?  ;)

Oliver
« Last Edit: December 01, 2009, 12:11:29 am by ofels »

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13471
  • Karma: +571/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: GUID integrity
« Reply #9 on: December 01, 2009, 12:16:10 am »
Quote
BTW, does it affect propability that I never play such things?  ;)
Naa, not significantly :D

Geert

Paolo F Cantoni

  • EA Guru
  • *****
  • Posts: 8617
  • Karma: +257/-129
  • Inconsistently correct systems DON'T EXIST!
    • View Profile
Re: GUID integrity
« Reply #10 on: December 01, 2009, 12:44:17 am »
Quote
But, then again, my problem is winning the lottery one time in a row.   :(
Well, of course, someone has to win...  (but the chances are it won't be you...)

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