Package org.apache.hadoop.yarn.security
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 Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor needed for the Service Loader.DockerCredentialTokenIdentifier(String registryUrl, String applicationId) -
Method Summary
Modifier and TypeMethodDescriptionbooleanGet the application ID.org.apache.hadoop.io.TextgetKind()Return the TokenIdentifier kind.org.apache.hadoop.yarn.proto.YarnSecurityTokenProtos.DockerCredentialTokenIdentifierProtogetProto()Return the ProtoBuf formatted data.Get the registry URL.org.apache.hadoop.security.UserGroupInformationgetUser()Return a remote user based on the registry URL and Application ID.inthashCode()voidreadFields(DataInput in) Populate the Proto object with the input.toString()voidwrite(DataOutput out) Write the TokenIdentifier to the output stream.Methods inherited from class org.apache.hadoop.security.token.TokenIdentifier
getBytes, getTrackingId
-
Field Details
-
KIND
public static final org.apache.hadoop.io.Text KIND
-
-
Constructor Details
-
DockerCredentialTokenIdentifier
-
DockerCredentialTokenIdentifier
public DockerCredentialTokenIdentifier()Default constructor needed for the Service Loader.
-
-
Method Details
-
write
Write the TokenIdentifier to the output stream.- Parameters:
out-DataOutputto serialize this object into.- Throws:
IOException- if the write fails.
-
readFields
Populate the Proto object with the input.- Parameters:
in-DataInputto 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:
getKindin classorg.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:
getUserin classorg.apache.hadoop.security.token.TokenIdentifier- Returns:
- a remote user based on the registry URL and Application ID.
-
getRegistryUrl
Get the registry URL.- Returns:
- the registry URL.
-
getApplicationId
Get the application ID.- Returns:
- the application ID.
-
hashCode
public int hashCode() -
equals
-
toString
-