Package org.apache.hadoop.ipc
Class ClientId
java.lang.Object
org.apache.hadoop.ipc.ClientId
A class defining a set of static helper methods to provide conversion between
bytes and string for UUID-based client Id.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe byte array of a UUID should be 16 -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
BYTE_LENGTH
public static final int BYTE_LENGTHThe byte array of a UUID should be 16- See Also:
-
-
Constructor Details
-
ClientId
public ClientId()
-
-
Method Details
-
getClientId
public static byte[] getClientId()- Returns:
- Return clientId as byte[].
-
toString
- Parameters:
clientId- input clientId.- Returns:
- Convert a clientId byte[] to string.
-
getMsb
public static long getMsb(byte[] clientId) -
getLsb
public static long getLsb(byte[] clientId) -
toBytes
- Parameters:
id- input id.- Returns:
- Convert from clientId string byte[] representation of clientId.
-