Record Class ManagedPartitionClient.Group

java.lang.Object
java.lang.Record
org.j7m.middleware.application.distributed.ManagedPartitionClient.Group
Record Components:
primary - authenticated default group endpoint
localities - finite host-approved same-group endpoint preferences, at most64
Enclosing class:
ManagedPartitionClient

public static record ManagedPartitionClient.Group(org.j7m.middleware.distributed.PartitionEndpoint primary, Map<String, org.j7m.middleware.distributed.PartitionEndpoint> localities) extends Record
Authorized endpoint alternatives within ONE native group; hints cannot change group authority.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Group(org.j7m.middleware.distributed.PartitionEndpoint primary, Map<String, org.j7m.middleware.distributed.PartitionEndpoint> localities)
    Snapshots endpoint references without opening connections.
  • Method Summary

    Modifier and Type
    Method
    Description
    final boolean
    Indicates whether some other object is "equal to" this one.
    final int
    Returns a hash code value for this object.
    Map<String, org.j7m.middleware.distributed.PartitionEndpoint>
    Returns the value of the localities record component.
    org.j7m.middleware.distributed.PartitionEndpoint
    Returns the value of the primary record component.
    Returns a fixed diagnostic without endpoints or credentials.

    Methods inherited from class Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • Group

      public Group(org.j7m.middleware.distributed.PartitionEndpoint primary, Map<String, org.j7m.middleware.distributed.PartitionEndpoint> localities)
      Snapshots endpoint references without opening connections.
      Throws:
      IllegalArgumentException - for invalid locality names or inventory capacity
      NullPointerException - for absent endpoints
  • Method Details

    • toString

      public String toString()
      Returns a fixed diagnostic without endpoints or credentials.
      Specified by:
      toString in class Record
      Returns:
      redacted group description
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • primary

      public org.j7m.middleware.distributed.PartitionEndpoint primary()
      Returns the value of the primary record component.
      Returns:
      the value of the primary record component
    • localities

      public Map<String, org.j7m.middleware.distributed.PartitionEndpoint> localities()
      Returns the value of the localities record component.
      Returns:
      the value of the localities record component