Class DockerCredentialTokenIdentifier

java.lang.Object
org.apache.hadoop.security.token.TokenIdentifier
org.apache.hadoop.yarn.security.DockerCredentialTokenIdentifier
All Implemented Interfaces:
org.apache.hadoop.io.Writable

public class DockerCredentialTokenIdentifier extends org.apache.hadoop.security.token.TokenIdentifier
TokenIdentifier for Docker registry credentials.
  • Field Details

    • KIND

      public static final org.apache.hadoop.io.Text KIND
  • Constructor Details

    • DockerCredentialTokenIdentifier

      public DockerCredentialTokenIdentifier(String registryUrl, String applicationId)
    • DockerCredentialTokenIdentifier

      public DockerCredentialTokenIdentifier()
      Default constructor needed for the Service Loader.
  • Method Details

    • write

      public void write(DataOutput out) throws IOException
      Write the TokenIdentifier to the output stream.
      Parameters:
      out - DataOutput to serialize this object into.
      Throws:
      IOException - if the write fails.
    • readFields

      public void readFields(DataInput in) throws IOException
      Populate the Proto object with the input.
      Parameters:
      in - DataInput to deserialize this object from.
      Throws:
      IOException - if the read fails.
    • getProto

      public org.apache.hadoop.yarn.proto.YarnSecurityTokenProtos.DockerCredentialTokenIdentifierProto getProto()
      Return the ProtoBuf formatted data.
      Returns:
      the ProtoBuf representation of the data.
    • getKind

      public org.apache.hadoop.io.Text getKind()
      Return the TokenIdentifier kind.
      Specified by:
      getKind in class org.apache.hadoop.security.token.TokenIdentifier
      Returns:
      the TokenIdentifier kind.
    • getUser

      public org.apache.hadoop.security.UserGroupInformation getUser()
      Return a remote user based on the registry URL and Application ID.
      Specified by:
      getUser in class org.apache.hadoop.security.token.TokenIdentifier
      Returns:
      a remote user based on the registry URL and Application ID.
    • getRegistryUrl

      public String getRegistryUrl()
      Get the registry URL.
      Returns:
      the registry URL.
    • getApplicationId

      public String getApplicationId()
      Get the application ID.
      Returns:
      the application ID.
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object other)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object