com.ibm.websphere.wim.common

Class EntryUuidGenerator

  • java.lang.Object
    • com.ibm.websphere.wim.common.EntryUuidGenerator


  • public class EntryUuidGenerator
    extends java.lang.Object
    This class implements a DCE UUID algorithm using the clock variant algorithm. It uses a pseudo adapter address based on the time the generator is initialized and a hash of the host name. The class generates a UUID string of the form:
    5e796ea0-57b2-11d6-8764-82fb3cc6fb79

    The class was written for LDAP applications using the ibm-appUUID attribute to uniquely identify an instance of an object (i.e. an attribute assigned once that stays with an entry through its life and is unique from other objects or even objects created at different times with the same name).

    This UUID will be unique across:

    1. UUIDs generated using other DCE UUID variants and version.
    2. UUIDs generated using the time-based variant that use real IEEE 802 adapter addresses
    They will also be unique with a high degree of confidence across:
    1. UUIDs generated generated using this algorithm, though there is a non-zero chance that another instance of this generator will generate the same fake node-id (requires same initial time to 1 sec and same 15 bit sum of chars in the host domain name) and 12-bit clock sequence.
    There is a lesser chance that the UUID will be unique across time based UUIDs that generate fake adapter methods using other means, though with 62 bits (15 bit clock sequence + 47 bits of adapter address), the odds of a collision on those portions of the UUID are roughly 1 in 2**62 (9 * 10**18)

    Even if those portion of the UUID match, the timestamps associated with an individual UUID would also have to match.

    To generate a UUID, call the newEntryUuid method.

    • Method Summary

      Methods 
      Modifier and Type Method and Description
      static java.lang.String newEntryUuid()
      Generates a UUID string
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • EntryUuidGenerator

        public EntryUuidGenerator()
    • Method Detail

      • newEntryUuid

        public static java.lang.String newEntryUuid()
        Generates a UUID string
        Return:
        the generated UUID