Record Class EndpointCertificate

java.lang.Object
java.lang.Record
com.yahoo.vespa.hosted.controller.api.integration.certificates.EndpointCertificate

public record EndpointCertificate(String keyName, String certName, int version, long lastRequested, String rootRequestId, Optional<String> leafRequestId, List<String> requestedDnsSans, String issuer, Optional<Long> expiry, Optional<Long> lastRefreshed, Optional<String> generatedId) extends Record
This holds information about an application's endpoint certificate.
Author:
andreer
  • Constructor Details

    • EndpointCertificate

      public EndpointCertificate(String keyName, String certName, int version, long lastRequested, String rootRequestId, Optional<String> leafRequestId, List<String> requestedDnsSans, String issuer, Optional<Long> expiry, Optional<Long> lastRefreshed, Optional<String> generatedId)
      Creates an instance of a EndpointCertificate record class.
      Parameters:
      keyName - the value for the keyName record component
      certName - the value for the certName record component
      version - the value for the version record component
      lastRequested - the value for the lastRequested record component
      rootRequestId - the value for the rootRequestId record component
      leafRequestId - the value for the leafRequestId record component
      requestedDnsSans - the value for the requestedDnsSans record component
      issuer - the value for the issuer record component
      expiry - the value for the expiry record component
      lastRefreshed - the value for the lastRefreshed record component
      generatedId - the value for the generatedId record component
  • Method Details

    • withGeneratedId

      public EndpointCertificate withGeneratedId(String generatedId)
    • withKeyName

      public EndpointCertificate withKeyName(String keyName)
    • withCertName

      public EndpointCertificate withCertName(String certName)
    • withVersion

      public EndpointCertificate withVersion(int version)
    • withLastRequested

      public EndpointCertificate withLastRequested(long lastRequested)
    • withLastRefreshed

      public EndpointCertificate withLastRefreshed(long lastRefreshed)
    • withRootRequestId

      public EndpointCertificate withRootRequestId(String rootRequestId)
    • withLeafRequestId

      public EndpointCertificate withLeafRequestId(Optional<String> leafRequestId)
    • sanMatches

      public boolean sanMatches(String dnsName)
      Returns whether given DNS name matches any of the requested SANs in this
    • 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.
    • keyName

      public String keyName()
      Returns the value of the keyName record component.
      Returns:
      the value of the keyName record component
    • certName

      public String certName()
      Returns the value of the certName record component.
      Returns:
      the value of the certName record component
    • version

      public int version()
      Returns the value of the version record component.
      Returns:
      the value of the version record component
    • lastRequested

      public long lastRequested()
      Returns the value of the lastRequested record component.
      Returns:
      the value of the lastRequested record component
    • rootRequestId

      public String rootRequestId()
      Returns the value of the rootRequestId record component.
      Returns:
      the value of the rootRequestId record component
    • leafRequestId

      public Optional<String> leafRequestId()
      Returns the value of the leafRequestId record component.
      Returns:
      the value of the leafRequestId record component
    • requestedDnsSans

      public List<String> requestedDnsSans()
      Returns the value of the requestedDnsSans record component.
      Returns:
      the value of the requestedDnsSans record component
    • issuer

      public String issuer()
      Returns the value of the issuer record component.
      Returns:
      the value of the issuer record component
    • expiry

      public Optional<Long> expiry()
      Returns the value of the expiry record component.
      Returns:
      the value of the expiry record component
    • lastRefreshed

      public Optional<Long> lastRefreshed()
      Returns the value of the lastRefreshed record component.
      Returns:
      the value of the lastRefreshed record component
    • generatedId

      public Optional<String> generatedId()
      Returns the value of the generatedId record component.
      Returns:
      the value of the generatedId record component