java.lang.Object
org.apache.hadoop.yarn.server.globalpolicygenerator.applicationcleaner.ApplicationCleaner
All Implemented Interfaces:
Runnable
Direct Known Subclasses:
DefaultApplicationCleaner

public abstract class ApplicationCleaner extends Object implements Runnable
The ApplicationCleaner is a runnable that cleans up old applications from table applicationsHomeSubCluster in FederationStateStore.
  • Constructor Details

    • ApplicationCleaner

      public ApplicationCleaner()
  • Method Details

    • init

      public void init(org.apache.hadoop.conf.Configuration config, GPGContext context) throws org.apache.hadoop.yarn.exceptions.YarnException
      Throws:
      org.apache.hadoop.yarn.exceptions.YarnException
    • getGPGContext

      public GPGContext getGPGContext()
    • getRegistryClient

      public org.apache.hadoop.yarn.server.federation.utils.FederationRegistryClient getRegistryClient()
    • getAppsFromRouter

      public Set<org.apache.hadoop.yarn.api.records.ApplicationId> getAppsFromRouter() throws org.apache.hadoop.yarn.exceptions.YarnRuntimeException
      Query router for applications.
      Returns:
      the set of applications
      Throws:
      org.apache.hadoop.yarn.exceptions.YarnRuntimeException - when router call fails
    • getRouterKnownApplications

      public Set<org.apache.hadoop.yarn.api.records.ApplicationId> getRouterKnownApplications() throws org.apache.hadoop.yarn.exceptions.YarnException
      Get the list of known applications in the cluster from Router.
      Returns:
      the list of known applications
      Throws:
      org.apache.hadoop.yarn.exceptions.YarnException - if get app fails
    • run

      public abstract void run()
      Specified by:
      run in interface Runnable