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 Summary
Constructors Constructor Description PBThreeTierETLPVLookup(ConfigService configService)
-
Method Summary
Modifier and Type Method Description void
addETLJobsForUnitTests(String pvName, PVTypeInfo typeInfo)
void
deleteETLJobs(String pvName)
Cancel the ETL jobs for each of the ETL lifetime transitions and also remove from internal structures.static OutOfSpaceHandling
determineOutOfSpaceHandling(ConfigService configService)
List<ETLMetricsForLifetime>
getApplianceMetrics()
Event
getLatestEventFromDataStores(String pvName)
Get the latest (last known) entry from the stores for this PV.LinkedList<ETLPVLookupItems>
getLookupItemsForPV(String pvName)
Get the internal state for all the ETL lifetime transitions for a pvvoid
manualControlForUnitTests()
Some unit tests want to run the ETL jobs manually; so we shut down the threads.void
postStartup()
Initialize the ETL background scheduled executors and create the runtime state for various ETL components.
-
-
-
Constructor Detail
-
PBThreeTierETLPVLookup
public PBThreeTierETLPVLookup(ConfigService configService)
-
-
Method Detail
-
postStartup
public void postStartup()
Initialize the ETL background scheduled executors and create the runtime state for various ETL components.
-
deleteETLJobs
public 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.
-
getLookupItemsForPV
public LinkedList<ETLPVLookupItems> getLookupItemsForPV(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 List<ETLMetricsForLifetime> getApplianceMetrics()
-
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)
-
-