Record Class SignedIdentityDocument

java.lang.Object
java.lang.Record
com.yahoo.vespa.athenz.identityprovider.api.SignedIdentityDocument

public record SignedIdentityDocument(String signature, int signingKeyVersion, VespaUniqueInstanceId providerUniqueId, AthenzService providerService, int documentVersion, String configServerHostname, String instanceHostname, Instant createdAt, Set<String> ipAddresses, IdentityType identityType, ClusterType clusterType, String ztsUrl, AthenzIdentity serviceIdentity, Map<String,Object> unknownAttributes) extends Record
A signed identity document. The unknownAttributes() member provides forward compatibility and ensures any new/unknown fields are kept intact when serialized to JSON.
Author:
bjorncs
  • Field Details

    • DEFAULT_DOCUMENT_VERSION

      public static final int DEFAULT_DOCUMENT_VERSION
      See Also:
  • Constructor Details

    • SignedIdentityDocument

      public SignedIdentityDocument(String signature, int signingKeyVersion, VespaUniqueInstanceId providerUniqueId, AthenzService providerService, int documentVersion, String configServerHostname, String instanceHostname, Instant createdAt, Set<String> ipAddresses, IdentityType identityType, ClusterType clusterType, String ztsUrl, AthenzIdentity serviceIdentity, Map<String,Object> unknownAttributes)
      Creates an instance of a SignedIdentityDocument record class.
      Parameters:
      signature - the value for the signature record component
      signingKeyVersion - the value for the signingKeyVersion record component
      providerUniqueId - the value for the providerUniqueId record component
      providerService - the value for the providerService record component
      documentVersion - the value for the documentVersion record component
      configServerHostname - the value for the configServerHostname record component
      instanceHostname - the value for the instanceHostname record component
      createdAt - the value for the createdAt record component
      ipAddresses - the value for the ipAddresses record component
      identityType - the value for the identityType record component
      clusterType - the value for the clusterType record component
      ztsUrl - the value for the ztsUrl record component
      serviceIdentity - the value for the serviceIdentity record component
      unknownAttributes - the value for the unknownAttributes record component
    • SignedIdentityDocument

      public SignedIdentityDocument(String signature, int signingKeyVersion, VespaUniqueInstanceId providerUniqueId, AthenzService providerService, int documentVersion, String configServerHostname, String instanceHostname, Instant createdAt, Set<String> ipAddresses, IdentityType identityType, ClusterType clusterType, String ztsUrl, AthenzIdentity serviceIdentity)
  • Method Details

    • outdated

      public boolean outdated()
    • withServiceIdentity

      public SignedIdentityDocument withServiceIdentity(AthenzIdentity identity)
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • 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. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      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.
    • signature

      public String signature()
      Returns the value of the signature record component.
      Returns:
      the value of the signature record component
    • signingKeyVersion

      public int signingKeyVersion()
      Returns the value of the signingKeyVersion record component.
      Returns:
      the value of the signingKeyVersion record component
    • providerUniqueId

      public VespaUniqueInstanceId providerUniqueId()
      Returns the value of the providerUniqueId record component.
      Returns:
      the value of the providerUniqueId record component
    • providerService

      public AthenzService providerService()
      Returns the value of the providerService record component.
      Returns:
      the value of the providerService record component
    • documentVersion

      public int documentVersion()
      Returns the value of the documentVersion record component.
      Returns:
      the value of the documentVersion record component
    • configServerHostname

      public String configServerHostname()
      Returns the value of the configServerHostname record component.
      Returns:
      the value of the configServerHostname record component
    • instanceHostname

      public String instanceHostname()
      Returns the value of the instanceHostname record component.
      Returns:
      the value of the instanceHostname record component
    • createdAt

      public Instant createdAt()
      Returns the value of the createdAt record component.
      Returns:
      the value of the createdAt record component
    • ipAddresses

      public Set<String> ipAddresses()
      Returns the value of the ipAddresses record component.
      Returns:
      the value of the ipAddresses record component
    • identityType

      public IdentityType identityType()
      Returns the value of the identityType record component.
      Returns:
      the value of the identityType record component
    • clusterType

      public ClusterType clusterType()
      Returns the value of the clusterType record component.
      Returns:
      the value of the clusterType record component
    • ztsUrl

      public String ztsUrl()
      Returns the value of the ztsUrl record component.
      Returns:
      the value of the ztsUrl record component
    • serviceIdentity

      public AthenzIdentity serviceIdentity()
      Returns the value of the serviceIdentity record component.
      Returns:
      the value of the serviceIdentity record component
    • unknownAttributes

      public Map<String,Object> unknownAttributes()
      Returns the value of the unknownAttributes record component.
      Returns:
      the value of the unknownAttributes record component