Enum Class AcquireReason

java.lang.Object
java.lang.Enum<AcquireReason>
me.ahoo.cosid.lease.AcquireReason
All Implemented Interfaces:
Serializable, Comparable<AcquireReason>, Constable

public enum AcquireReason extends Enum<AcquireReason>
Which step of the slot choice (05-machine-lease.md ยง2.1) gave the slot; the store reports it, for observation only.
  • Enum Constant Details

    • IDEMPOTENT

      public static final AcquireReason IDEMPOTENT
      The owner, same key and incarnation, already held the slot: a retried acquire.
    • PREFERRED

      public static final AcquireReason PREFERRED
      The free preferred slot.
    • STICKY

      public static final AcquireReason STICKY
      The free slot the owner key held last.
    • LOWEST

      public static final AcquireReason LOWEST
      The lowest free slot.
  • Method Details

    • values

      public static AcquireReason[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static AcquireReason valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • label

      public String label()
      The name the listener events use (idempotent, preferred, sticky, lowest).
      Returns:
      the lower case name