org.ehcache.management.registry
Class DefaultManagementRegistryService
java.lang.Object
org.terracotta.management.registry.AbstractManagementRegistry
org.ehcache.management.registry.DefaultManagementRegistryService
- All Implemented Interfaces:
- CacheManagerListener, StateChangeListener, ManagementRegistryService, Service, org.terracotta.management.registry.CapabilityManagementSupport, org.terracotta.management.registry.ManagementRegistry
public class DefaultManagementRegistryService
- extends org.terracotta.management.registry.AbstractManagementRegistry
- implements ManagementRegistryService, CacheManagerListener
Fields inherited from class org.terracotta.management.registry.AbstractManagementRegistry |
managementProviders |
Methods inherited from class org.terracotta.management.registry.AbstractManagementRegistry |
addManagementProvider, getCapabilities, getManagementProvidersByCapability, register, removeManagementProvider, unregister, withCapability |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.terracotta.management.registry.ManagementRegistry |
addManagementProvider, getCapabilities, register, removeManagementProvider, unregister |
Methods inherited from interface org.terracotta.management.registry.CapabilityManagementSupport |
getManagementProvidersByCapability, withCapability |
DefaultManagementRegistryService
public DefaultManagementRegistryService()
DefaultManagementRegistryService
public DefaultManagementRegistryService(ManagementRegistryServiceConfiguration configuration)
start
public void start(ServiceProvider<Service> serviceProvider)
- Description copied from interface:
Service
- Start this service using the provided configuration and
ServiceProvider
.
The goal of the service provider is to allow a service to use other services.
- Specified by:
start
in interface Service
- Parameters:
serviceProvider
- the service provider.
stop
public void stop()
- Description copied from interface:
Service
- Stops this service.
- Specified by:
stop
in interface Service
cacheAdded
public void cacheAdded(java.lang.String alias,
Cache<?,?> cache)
- Description copied from interface:
CacheManagerListener
- Fires just after the @{link Cache} was made
Status.AVAILABLE
, but wasn't yet made available
to other threads by the CacheManager
. Nonetheless, no other thread can add another Cache
instance by the same alias.
- Specified by:
cacheAdded
in interface CacheManagerListener
- Parameters:
alias
- the alias the Cache
is being registered oncache
- the actual Cache
added
cacheRemoved
public void cacheRemoved(java.lang.String alias,
Cache<?,?> cache)
- Description copied from interface:
CacheManagerListener
- Fires just after the @{link Cache} was deregistered with the
CacheManager
, but wasn't yet made
Status.UNINITIALIZED
. So that no other thread can get a handle to this Cache
anymore,
but the CacheManagerListener
can still interact with it
- Specified by:
cacheRemoved
in interface CacheManagerListener
- Parameters:
alias
- the alias the Cache
is being deregisteredcache
- the actual Cache
being removed
stateTransition
public void stateTransition(Status from,
Status to)
- Description copied from interface:
StateChangeListener
- Is notified when a state transition occurred.
Any exception thrown by this listener will not affect the transition.
- Specified by:
stateTransition
in interface StateChangeListener
- Parameters:
from
- previous stateto
- new state
getConfiguration
public ManagementRegistryServiceConfiguration getConfiguration()
- Specified by:
getConfiguration
in interface ManagementRegistryService
- Returns:
- This registry configuration
getContextContainer
public org.terracotta.management.context.ContextContainer getContextContainer()
- Specified by:
getContextContainer
in interface org.terracotta.management.registry.ManagementRegistry