public abstract class DistributedCacheInvalidationCounter<M> extends Object
ITopic
s, using Micrometer.
This is an abstract class, and subclasses are responsible for determining which topics are used, and how to decode
the messages on them.HazelcastTopicMessageRouter
Modifier and Type | Class and Description |
---|---|
protected static class |
DistributedCacheInvalidationCounter.InvalidationType |
Constructor and Description |
---|
DistributedCacheInvalidationCounter(HazelcastTopicMessageRouter messageRouter,
io.micrometer.core.instrument.MeterRegistry meterRegistry,
com.atlassian.event.api.EventListenerRegistrar eventListenerRegistrar) |
Modifier and Type | Method and Description |
---|---|
protected abstract String |
cacheType() |
static DistributedCacheInvalidationCounter<Object> |
forAtlassianCache(com.atlassian.cache.CacheManager cacheManager,
HazelcastTopicMessageRouter messageRouter,
io.micrometer.core.instrument.MeterRegistry meterRegistry,
com.atlassian.event.api.EventListenerRegistrar eventListenerRegistrar)
Creates a
DistributedCacheInvalidationCounter that counts invalidations published by HazelcastAsyncHybridCache . |
static DistributedCacheInvalidationCounter<com.hazelcast.hibernate.local.Invalidation> |
forHibernateL2CacheRegions(org.hibernate.SessionFactory sessionFactory,
HazelcastTopicMessageRouter messageRouter,
io.micrometer.core.instrument.MeterRegistry meterRegistry,
com.atlassian.event.api.EventListenerRegistrar eventListenerRegistrar)
Creates a
DistributedCacheInvalidationCounter that counts invalidations published by LocalRegionCache
via HazelcastHibernateRegionFactory . |
protected abstract String |
getCacheName(String topicName) |
protected abstract Stream<String> |
getInvalidationTopicNames() |
protected abstract DistributedCacheInvalidationCounter.InvalidationType |
invalidationType(M message) |
void |
onTenantArrived(com.atlassian.tenancy.api.event.TenantArrivedEvent event) |
void |
registerForTenantArrivalEvent() |
void |
unregisterFromEvents() |
public DistributedCacheInvalidationCounter(HazelcastTopicMessageRouter messageRouter, io.micrometer.core.instrument.MeterRegistry meterRegistry, com.atlassian.event.api.EventListenerRegistrar eventListenerRegistrar)
@PostConstruct public void registerForTenantArrivalEvent()
@PreDestroy public void unregisterFromEvents()
@EventListener public void onTenantArrived(com.atlassian.tenancy.api.event.TenantArrivedEvent event)
protected abstract String cacheType()
protected abstract DistributedCacheInvalidationCounter.InvalidationType invalidationType(M message)
public static DistributedCacheInvalidationCounter<com.hazelcast.hibernate.local.Invalidation> forHibernateL2CacheRegions(org.hibernate.SessionFactory sessionFactory, HazelcastTopicMessageRouter messageRouter, io.micrometer.core.instrument.MeterRegistry meterRegistry, com.atlassian.event.api.EventListenerRegistrar eventListenerRegistrar)
DistributedCacheInvalidationCounter
that counts invalidations published by LocalRegionCache
via HazelcastHibernateRegionFactory
.public static DistributedCacheInvalidationCounter<Object> forAtlassianCache(com.atlassian.cache.CacheManager cacheManager, HazelcastTopicMessageRouter messageRouter, io.micrometer.core.instrument.MeterRegistry meterRegistry, com.atlassian.event.api.EventListenerRegistrar eventListenerRegistrar)
DistributedCacheInvalidationCounter
that counts invalidations published by HazelcastAsyncHybridCache
.Copyright © 2003–2020 Atlassian. All rights reserved.