Class PBThreeTierETLPVLookup

java.lang.Object
org.epics.archiverappliance.etl.common.PBThreeTierETLPVLookup

public final class PBThreeTierETLPVLookup extends Object
Holds runtime state for ETL. For now, gets all of the info from PVTypeInfo.
Version:
4-Jun-2012, Luofeng Li:added codes to create one ETL thread for each ETL
Author:
rdh
  • Constructor Details

    • PBThreeTierETLPVLookup

      public PBThreeTierETLPVLookup(ConfigService configService)
  • Method Details

    • postStartup

      public void postStartup()
      Initialize the ETL background scheduled executors and create the runtime state for various ETL components.
    • pvTypeInfoChanged

      public void pvTypeInfoChanged(PVTypeInfoEvent event)
    • deleteETLJobs

      public CompletableFuture<Void> deleteETLJobs(String pvName)
      Cancel the ETL jobs for each of the ETL lifetime transitions and also remove from internal structures.
      Parameters:
      pvName - The name of PV.
    • getETLStages

      public ETLStages getETLStages(String pvName)
      Get the internal state for all the ETL lifetime transitions for a pv
      Parameters:
      pvName - The name of PV.
      Returns:
      LinkedList  
    • getLatestEventFromDataStores

      public Event getLatestEventFromDataStores(String pvName) throws IOException
      Get the latest (last known) entry from the stores for this PV.
      Parameters:
      pvName - The name of PV.
      Returns:
      Event LatestEventFromDataStores
      Throws:
      IOException -  
    • getApplianceMetrics

      public ETLMetrics getApplianceMetrics()
    • getIsRunningInsideUnitTests

      public boolean getIsRunningInsideUnitTests()
    • manualControlForUnitTests

      public void manualControlForUnitTests()
      Some unit tests want to run the ETL jobs manually; so we shut down the threads. We should probably write a pausable thread pool executor Use with care.
    • determineOutOfSpaceHandling

      public static OutOfSpaceHandling determineOutOfSpaceHandling(ConfigService configService)
    • addETLJobsForUnitTests

      public void addETLJobsForUnitTests(String pvName, PVTypeInfo typeInfo)