Package org.dataloader.stats
Interface StatisticsCollector
-
- All Known Implementing Classes:
DelegatingStatisticsCollector,NoOpStatisticsCollector,SimpleStatisticsCollector,ThreadLocalStatisticsCollector
@PublicSpi public interface StatisticsCollector
This allows statistics to be collected forDataLoaderoperations
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Deprecated Methods Modifier and Type Method Description StatisticsgetStatistics()longincrementBatchLoadCountBy(long delta)default <K> longincrementBatchLoadCountBy(long delta, IncrementBatchLoadCountByStatisticsContext<K> context)Called to increment the number of batch loadslongincrementBatchLoadExceptionCount()default <K> longincrementBatchLoadExceptionCount(IncrementBatchLoadExceptionCountStatisticsContext<K> context)Called to increment the number of batch loads exceptionslongincrementCacheHitCount()Deprecated.default <K> longincrementCacheHitCount(IncrementCacheHitCountStatisticsContext<K> context)Called to increment the number of cache hitslongincrementLoadCount()Deprecated.default <K> longincrementLoadCount(IncrementLoadCountStatisticsContext<K> context)Called to increment the number of loadslongincrementLoadErrorCount()default <K> longincrementLoadErrorCount(IncrementLoadErrorCountStatisticsContext<K> context)Called to increment the number of loads that resulted in an object deemed in error
-
-
-
Method Detail
-
incrementLoadCount
default <K> long incrementLoadCount(IncrementLoadCountStatisticsContext<K> context)
Called to increment the number of loads- Type Parameters:
K- the class of the key in the data loader- Parameters:
context- the context containing metadata of the data loader invocation- Returns:
- the current value after increment
-
incrementLoadCount
@Deprecated long incrementLoadCount()
Deprecated.Called to increment the number of loads- Returns:
- the current value after increment
-
incrementLoadErrorCount
default <K> long incrementLoadErrorCount(IncrementLoadErrorCountStatisticsContext<K> context)
Called to increment the number of loads that resulted in an object deemed in error- Type Parameters:
K- the class of the key in the data loader- Parameters:
context- the context containing metadata of the data loader invocation- Returns:
- the current value after increment
-
incrementLoadErrorCount
@Deprecated long incrementLoadErrorCount()
Called to increment the number of loads that resulted in an object deemed in error- Returns:
- the current value after increment
-
incrementBatchLoadCountBy
default <K> long incrementBatchLoadCountBy(long delta, IncrementBatchLoadCountByStatisticsContext<K> context)Called to increment the number of batch loads- Type Parameters:
K- the class of the key in the data loader- Parameters:
delta- how much to add to the countcontext- the context containing metadata of the data loader invocation- Returns:
- the current value after increment
-
incrementBatchLoadCountBy
@Deprecated long incrementBatchLoadCountBy(long delta)
Called to increment the number of batch loads- Parameters:
delta- how much to add to the count- Returns:
- the current value after increment
-
incrementBatchLoadExceptionCount
default <K> long incrementBatchLoadExceptionCount(IncrementBatchLoadExceptionCountStatisticsContext<K> context)
Called to increment the number of batch loads exceptions- Type Parameters:
K- the class of the key in the data loader- Parameters:
context- the context containing metadata of the data loader invocation- Returns:
- the current value after increment
-
incrementBatchLoadExceptionCount
@Deprecated long incrementBatchLoadExceptionCount()
Called to increment the number of batch loads exceptions- Returns:
- the current value after increment
-
incrementCacheHitCount
default <K> long incrementCacheHitCount(IncrementCacheHitCountStatisticsContext<K> context)
Called to increment the number of cache hits- Type Parameters:
K- the class of the key in the data loader- Parameters:
context- the context containing metadata of the data loader invocation- Returns:
- the current value after increment
-
incrementCacheHitCount
@Deprecated long incrementCacheHitCount()
Deprecated.Called to increment the number of cache hits- Returns:
- the current value after increment
-
getStatistics
Statistics getStatistics()
- Returns:
- the statistics that have been gathered to this point in time
-
-