Class CaffeineCacheStats
java.lang.Object
com.palantir.tritium.metrics.caffeine.CaffeineCacheStats
-
Method Summary
Modifier and TypeMethodDescriptionstatic voidregisterCache(com.codahale.metrics.MetricRegistry registry, com.github.benmanes.caffeine.cache.Cache<?, ?> cache, String name) Deprecated.static voidregisterCache(com.palantir.tritium.metrics.registry.TaggedMetricRegistry registry, com.github.benmanes.caffeine.cache.Cache<?, ?> cache, @Safe String name) Deprecated.PreferCacheStats.of(TaggedMetricRegistry, String).register(stats ->Caffeine.newBuilder().recordStats(stats)}...
-
Method Details
-
registerCache
@Deprecated public static void registerCache(com.codahale.metrics.MetricRegistry registry, com.github.benmanes.caffeine.cache.Cache<?, ?> cache, String name) Deprecated.Register specified cache with the given metric registry.Callers should ensure that they have
enabled stats recordingCaffeine.newBuilder().recordStats()otherwise there are no cache metrics to register.- Parameters:
registry- metric registrycache- cache to instrumentname- cache name
-
registerCache
@Deprecated public static void registerCache(com.palantir.tritium.metrics.registry.TaggedMetricRegistry registry, com.github.benmanes.caffeine.cache.Cache<?, ?> cache, @Safe @Safe String name) Deprecated.PreferCacheStats.of(TaggedMetricRegistry, String).register(stats ->Caffeine.newBuilder().recordStats(stats)}... See Instrumenting a [Caffeine cache](https://github.com/ben-manes/caffeine/)Register specified cache with the given metric registry.Callers should ensure that they have
enabled stats recordingCaffeine.newBuilder().recordStats()otherwise there are no cache metrics to register.- Parameters:
registry- metric registrycache- cache to instrumentname- cache name
-
registerCache(TaggedMetricRegistry, Cache, String)