Class HeartbeatVersionedStats
java.lang.Object
com.linkedin.davinci.stats.AbstractVeniceAggVersionedStats<HeartbeatStat,HeartbeatStatReporter>
com.linkedin.davinci.stats.ingestion.heartbeat.HeartbeatVersionedStats
- All Implemented Interfaces:
StoreDataChangedListener
public class HeartbeatVersionedStats
extends AbstractVeniceAggVersionedStats<HeartbeatStat,HeartbeatStatReporter>
-
Field Summary
Fields inherited from class com.linkedin.davinci.stats.AbstractVeniceAggVersionedStats
metadataRepository -
Constructor Summary
ConstructorsConstructorDescriptionHeartbeatVersionedStats(io.tehuti.metrics.MetricsRepository metricsRepository, ReadOnlyStoreRepository metadataRepository, Supplier<HeartbeatStat> statsInitiator, StatsSupplier<HeartbeatStatReporter> reporterSupplier, Map<String, Map<Integer, Map<Integer, Map<String, HeartbeatTimeStampEntry>>>> leaderMonitors, Map<String, Map<Integer, Map<Integer, Map<String, HeartbeatTimeStampEntry>>>> followerMonitors, String clusterName) -
Method Summary
Modifier and TypeMethodDescriptionvoidhandleStoreChanged(Store store) voidhandleStoreCreated(Store store) Do NOT try to acquire the lock of store repository again in the implementation, otherwise a dead lock issue will happen.voidprotected voidonVersionInfoUpdated(String storeName, int currentVersion, int futureVersion) Hook method called when version info is updated for a store.voidrecordFollowerLag(String storeName, int version, String region, long heartbeatTs, boolean isReadyToServe) voidrecordLeaderLag(String storeName, int version, String region, long heartbeatTs) Methods inherited from class com.linkedin.davinci.stats.AbstractVeniceAggVersionedStats
addStore, getCurrentVersion, getFutureVersion, getMetricsRepository, getStats, getTotalStats, handleStoreDeleted, recordVersionedAndTotalStat, registerConditionalStats, updateStatsVersionInfo, updateTotalStatsMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.linkedin.venice.meta.StoreDataChangedListener
handleStoreDeleted
-
Constructor Details
-
HeartbeatVersionedStats
public HeartbeatVersionedStats(io.tehuti.metrics.MetricsRepository metricsRepository, ReadOnlyStoreRepository metadataRepository, Supplier<HeartbeatStat> statsInitiator, StatsSupplier<HeartbeatStatReporter> reporterSupplier, Map<String, Map<Integer, Map<Integer, Map<String, HeartbeatTimeStampEntry>>>> leaderMonitors, Map<String, Map<Integer, Map<Integer, Map<String, HeartbeatTimeStampEntry>>>> followerMonitors, String clusterName)
-
-
Method Details
-
recordLeaderLag
-
recordFollowerLag
-
loadAllStats
public void loadAllStats()- Overrides:
loadAllStatsin classAbstractVeniceAggVersionedStats<HeartbeatStat,HeartbeatStatReporter>
-
handleStoreCreated
Description copied from interface:StoreDataChangedListenerDo NOT try to acquire the lock of store repository again in the implementation, otherwise a dead lock issue will happen.- Specified by:
handleStoreCreatedin interfaceStoreDataChangedListener- Overrides:
handleStoreCreatedin classAbstractVeniceAggVersionedStats<HeartbeatStat,HeartbeatStatReporter>
-
handleStoreChanged
- Specified by:
handleStoreChangedin interfaceStoreDataChangedListener- Overrides:
handleStoreChangedin classAbstractVeniceAggVersionedStats<HeartbeatStat,HeartbeatStatReporter>
-
onVersionInfoUpdated
Description copied from class:AbstractVeniceAggVersionedStatsHook method called when version info is updated for a store. Subclasses can override this to react to version changes.- Overrides:
onVersionInfoUpdatedin classAbstractVeniceAggVersionedStats<HeartbeatStat,HeartbeatStatReporter> - Parameters:
storeName- The store whose version info changedcurrentVersion- The new current versionfutureVersion- The new future version
-