public class FederationGuavaCache extends FederationCache
FederationCache.ApplicationHomeSubClusterCacheResponse, FederationCache.CacheRequest<K,V>, FederationCache.CacheResponse<R>, FederationCache.SubClusterInfoCacheResponse, FederationCache.SubClusterPolicyConfigurationCacheResponseGET_APPLICATION_HOME_SUBCLUSTER_CACHEID, GET_POLICIES_CONFIGURATIONS_CACHEID, GET_SUBCLUSTERS_CACHEID, POINT| Constructor | Description |
|---|---|
FederationGuavaCache() |
| Modifier and Type | Method | Description |
|---|---|---|
void |
clearCache() |
clear cache.
|
SubClusterId |
getApplicationHomeSubCluster(org.apache.hadoop.yarn.api.records.ApplicationId appId) |
Returns the home
SubClusterId for the specified
ApplicationId. |
java.util.Map<java.lang.String,SubClusterPolicyConfiguration> |
getPoliciesConfigurations() |
Get the policies that is represented as
SubClusterPolicyConfiguration for all currently active queues in
the system. |
java.util.Map<SubClusterId,SubClusterInfo> |
getSubClusters(boolean filterInactiveSubClusters) |
Returns the
SubClusterInfo of all active sub cluster(s). |
void |
initCache(org.apache.hadoop.conf.Configuration pConf,
FederationStateStore pStateStore) |
Initialize the cache.
|
boolean |
isCachingEnabled() |
Determine whether to enable cache.
|
void |
removeSubCluster(boolean flushCache) |
Remove SubCluster from cache.
|
buildCacheKey, buildCacheKey, buildGetApplicationHomeSubClusterRequest, buildGetPoliciesConfigurationsCacheRequest, buildGetSubClustersCacheRequest, buildPolicyConfigMap, buildPolicyConfigMap, buildSubClusterInfoMap, buildSubClusterInfoMap, getStateStore, setStateStorepublic boolean isCachingEnabled()
FederationCacheisCachingEnabled in class FederationCachepublic void initCache(org.apache.hadoop.conf.Configuration pConf,
FederationStateStore pStateStore)
FederationCacheinitCache in class FederationCachepConf - Configuration.pStateStore - FederationStateStore.public void clearCache()
FederationCacheclearCache in class FederationCachepublic java.util.Map<SubClusterId,SubClusterInfo> getSubClusters(boolean filterInactiveSubClusters) throws org.apache.hadoop.yarn.exceptions.YarnException
FederationCacheSubClusterInfo of all active sub cluster(s).getSubClusters in class FederationCachefilterInactiveSubClusters - whether to filter out inactive
sub-clustersorg.apache.hadoop.yarn.exceptions.YarnException - if the call to the state store is unsuccessfulpublic java.util.Map<java.lang.String,SubClusterPolicyConfiguration> getPoliciesConfigurations() throws java.lang.Exception
FederationCacheSubClusterPolicyConfiguration for all currently active queues in
the system.getPoliciesConfigurations in class FederationCacheorg.apache.hadoop.yarn.exceptions.YarnException - if the call to the state store is unsuccessfuljava.lang.Exceptionpublic SubClusterId getApplicationHomeSubCluster(org.apache.hadoop.yarn.api.records.ApplicationId appId) throws java.lang.Exception
FederationCacheSubClusterId for the specified
ApplicationId.getApplicationHomeSubCluster in class FederationCacheappId - the identifier of the applicationorg.apache.hadoop.yarn.exceptions.YarnException - if the call to the state store is unsuccessfuljava.lang.Exceptionpublic void removeSubCluster(boolean flushCache)
FederationCacheremoveSubCluster in class FederationCacheflushCache - whether to filter out inactive
sub-clusters.Copyright © 2008–2025 Apache Software Foundation. All rights reserved.