Class RemoteLocation
java.lang.Object
org.apache.hadoop.hdfs.server.federation.router.RemoteLocationContext
org.apache.hadoop.hdfs.server.federation.resolver.RemoteLocation
- All Implemented Interfaces:
Comparable<RemoteLocationContext>
A location in a remote namespace consisting of a nameservice ID and a HDFS
path (destination). It also contains the federated location (source).
-
Constructor Summary
ConstructorsConstructorDescriptionRemoteLocation(String nsId, String dPath, String sPath) Create a new remote location.RemoteLocation(String nsId, String nnId, String dPath, String sPath) Create a new remote location pointing to a particular namenode in the namespace.RemoteLocation(RemoteLocation remoteLocation, String path) Use the Ns and Nn of a remote location and another path to create a new remote location pointing. -
Method Summary
Methods inherited from class org.apache.hadoop.hdfs.server.federation.router.RemoteLocationContext
compareTo, equals, hashCode
-
Constructor Details
-
RemoteLocation
Create a new remote location.- Parameters:
nsId- Destination namespace.dPath- Path in the destination namespace.sPath- Path in the federated level.
-
RemoteLocation
Create a new remote location pointing to a particular namenode in the namespace.- Parameters:
nsId- Destination namespace.nnId- Destination namenode.dPath- Path in the destination namespace.sPath- Path in the federated level
-
RemoteLocation
Use the Ns and Nn of a remote location and another path to create a new remote location pointing.- Parameters:
remoteLocation- A remoteLocation.path- Path in the destination namespace.
-
-
Method Details
-
getNameserviceId
Description copied from class:RemoteLocationContextReturns an identifier for a unique namespace.- Specified by:
getNameserviceIdin classRemoteLocationContext- Returns:
- Namespace identifier.
-
getDest
Description copied from class:RemoteLocationContextDestination in this location. For example the path in a remote namespace.- Specified by:
getDestin classRemoteLocationContext- Returns:
- Destination in this location.
-
getSrc
Description copied from class:RemoteLocationContextOriginal source location.- Specified by:
getSrcin classRemoteLocationContext- Returns:
- Source path.
-
toString
-