[unrev-II] Unique IDs (was Re: Jack's Use Case...)

From: Paul Fernhout (pdfernhout@kurtz-fernhout.com)
Date: Fri Oct 27 2000 - 07:57:04 PDT

  • Next message: Paul Fernhout: "[unrev-II] Poetry and Knowledge Management (was Jack's Use Case)"

    For one project I released in march for Squeak (a GUI system called
    "Links World" that works by defining a network of GUI objects (not
    nested GUI objects as most systems)) I created globally unique
    identifiers for each GUI elements. I used something like these parts:
      URL (Assumption -- these are uniquely managed)
      Creator unique ID (assumption -- within a URL someone can take charge
    of these)
      Data and Time stamp
      Random number
      Version number (for remapping if needed on import collisions, starts
    at 0, can increment if needed for referencing others data)

    Some display code:

    LinksUniqueID>>storeOn: aStream
            "Append to the argument, aStream, a sequence of characters that
            identifies the receiver."

        aStream nextPutAll: '(', self class name.
        aStream nextPutAll: ' d: '.
        aStream nextPutAll: domainSymbol storeString.
        aStream nextPutAll: ' c: '.
        aStream nextPutAll: creatorSymbol storeString.
        aStream nextPutAll: ' t: '.
        aStream nextPutAll: self timestamp storeString.
        aStream nextPutAll: ' r: '.
        aStream nextPutAll: randomNumber storeString.
        aStream nextPutAll: ' v: '.
        aStream nextPutAll: version storeString.
        aStream nextPutAll: ')'.

    I assumed that collisions could still happen, so I added the version
    field to be able to handle them on import if they were somehow detected.

    Note that
    -Paul Fernhout
    Kurtz-Fernhout Software
    Developers of custom software and educational simulations
    Creators of the Garden with Insight(TM) garden simulator

    Eric Armstrong wrote:
    > Jack Park wrote:
    > >
    > > The topic maps folks do this with a *public subject* which is being
    > > defined as a registered URN. Registering URNs doesn't appear to be
    > > all that easy.
    > >
    > > In a closed system, you just start with the number 0, grab a couple of
    > > numbers for some reserved things, then start giving every concept a
    > > new, unique number. Pointrel does this. I suppose you'll need to use long
    > > integers to pull that off, but, what the heck. Problem is, you cannot
    > > share with others; that requires grabbing numbers from some registry.
    > > Unique URLs
    > >
    > I'm delighted to say that I have solved this problem, at least in
    > principle. The combination of a globally unique userID (say
    > country+ID#),
    > plus a globally unique systemID (say, IP address) that includes a CPU
    > identifier, in a multiple CPU system, plus a synchronized,
    > miliisecond-level time stamp, produces a globally unique node ID.
    > That mechanisms allows peer-to-peer node sharing.
    > It seems like a lot of information, but except for the time-stamp,
    > nodes only need pointers to shared IDs, so the resource requirements
    > aren't too extreme.

    -------------------------- eGroups Sponsor -------------------------~-~>
    Last minute trips at
    first-rate discounts
    from Hotwire.

    Community email addresses:
      Post message: unrev-II@onelist.com
      Subscribe: unrev-II-subscribe@onelist.com
      Unsubscribe: unrev-II-unsubscribe@onelist.com
      List owner: unrev-II-owner@onelist.com

    Shortcut URL to this page:

    This archive was generated by hypermail 2b29 : Fri Oct 27 2000 - 08:46:56 PDT