Class RMApplicationHistoryWriter

java.lang.Object
org.apache.hadoop.service.AbstractService
org.apache.hadoop.service.CompositeService
org.apache.hadoop.yarn.server.resourcemanager.ahs.RMApplicationHistoryWriter
All Implemented Interfaces:
Closeable, AutoCloseable, org.apache.hadoop.service.Service

@Private @Unstable public class RMApplicationHistoryWriter extends org.apache.hadoop.service.CompositeService

ResourceManager uses this class to write the information of RMApp, RMAppAttempt and RMContainer. These APIs are non-blocking, and just schedule a writing history event. An self-contained dispatcher vector will handle the event in separate threads, and extract the required fields that are going to be persisted. Then, the extracted information will be persisted via the implementation of ApplicationHistoryStore.

  • Field Details

    • LOG

      public static final org.slf4j.Logger LOG
  • Constructor Details

    • RMApplicationHistoryWriter

      public RMApplicationHistoryWriter()
  • Method Details

    • serviceInit

      protected void serviceInit(org.apache.hadoop.conf.Configuration conf) throws Exception
      Overrides:
      serviceInit in class org.apache.hadoop.service.CompositeService
      Throws:
      Exception
    • createDispatcher

      protected org.apache.hadoop.yarn.event.Dispatcher createDispatcher(org.apache.hadoop.conf.Configuration conf)
    • createApplicationHistoryStore

      protected org.apache.hadoop.yarn.server.applicationhistoryservice.ApplicationHistoryStore createApplicationHistoryStore(org.apache.hadoop.conf.Configuration conf)
    • handleWritingApplicationHistoryEvent

      protected void handleWritingApplicationHistoryEvent(WritingApplicationHistoryEvent event)
    • applicationStarted

      public void applicationStarted(RMApp app)
    • applicationFinished

      public void applicationFinished(RMApp app, RMAppState finalState)
    • applicationAttemptStarted

      public void applicationAttemptStarted(RMAppAttempt appAttempt)
    • applicationAttemptFinished

      public void applicationAttemptFinished(RMAppAttempt appAttempt, RMAppAttemptState finalState)
    • containerStarted

      public void containerStarted(RMContainer container)
    • containerFinished

      public void containerFinished(RMContainer container)