Class RouterAsyncStoragePolicy
java.lang.Object
org.apache.hadoop.hdfs.server.federation.router.RouterStoragePolicy
org.apache.hadoop.hdfs.server.federation.router.async.RouterAsyncStoragePolicy
Module that implements all the asynchronous RPC calls in
ClientProtocol related to
Storage Policy in the RouterRpcServer.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.apache.hadoop.hdfs.protocol.BlockStoragePolicy[]Asynchronously get an array of all available storage policies.org.apache.hadoop.hdfs.protocol.BlockStoragePolicygetStoragePolicy(String path) Asynchronously get the storage policy for a given path.Methods inherited from class org.apache.hadoop.hdfs.server.federation.router.RouterStoragePolicy
satisfyStoragePolicy, setStoragePolicy, unsetStoragePolicy
-
Constructor Details
-
RouterAsyncStoragePolicy
-
-
Method Details
-
getStoragePolicy
public org.apache.hadoop.hdfs.protocol.BlockStoragePolicy getStoragePolicy(String path) throws IOException Asynchronously get the storage policy for a given path. This method checks the operation category and then invokes the getStoragePolicy method sequentially for the given path.- Overrides:
getStoragePolicyin classRouterStoragePolicy- Parameters:
path- The path for which to retrieve the storage policy.- Returns:
- The BlockStoragePolicy for the given path.
- Throws:
IOException- If an I/O error occurs.
-
getStoragePolicies
Asynchronously get an array of all available storage policies. This method checks the operation category and then invokes the getStoragePolicies method across all available namespaces.- Overrides:
getStoragePoliciesin classRouterStoragePolicy- Returns:
- An array of BlockStoragePolicy.
- Throws:
IOException- If an I/O error occurs.
-