Package org.infinispan.factories
Class GlobalComponentRegistry
- java.lang.Object
-
- org.infinispan.factories.AbstractComponentRegistry
-
- org.infinispan.factories.GlobalComponentRegistry
-
- All Implemented Interfaces:
java.lang.Cloneable,Lifecycle
@ThreadSafe public class GlobalComponentRegistry extends AbstractComponentRegistry
A global component registry where shared components are stored.- Since:
- 4.0
- Author:
- Manik Surtani
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.infinispan.factories.AbstractComponentRegistry
AbstractComponentRegistry.Component
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.ClassLoaderclassLoader-
Fields inherited from class org.infinispan.factories.AbstractComponentRegistry
DEBUG_DEPENDENCIES, state
-
-
Constructor Summary
Constructors Constructor Description GlobalComponentRegistry(GlobalConfiguration configuration, EmbeddedCacheManager cacheManager, java.util.Set<java.lang.String> createdCaches, ModuleRepository moduleRepository)Creates an instance of the component registry.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description protected voidaddShutdownHook()EmbeddedCacheManagergetCacheManager()protected java.lang.ClassLoadergetClassLoader()ComponentMetadataRepogetComponentMetadataRepo()Deprecated.Since 10.0, the component metadata repository is empty and no longer used.GlobalConfigurationgetGlobalConfiguration()protected org.infinispan.util.logging.LoggetLog()java.util.Map<java.lang.Byte,org.infinispan.commands.module.ModuleCommandInitializer>getModuleCommandInitializers()ModulePropertiesgetModuleProperties()ComponentRegistrygetNamedComponentRegistry(java.lang.String name)ComponentRegistrygetNamedComponentRegistry(ByteString name)TimeServicegetTimeService()voidnotifyCacheStarted(java.lang.String cacheName)protected voidpostStart()protected voidpostStop()protected voidpreStart()protected voidpreStop()voidregisterNamedComponentRegistry(ComponentRegistry componentRegistry, java.lang.String name)booleanremoveCache(java.lang.String cacheName)Removes a cache with the given name, returning true if the cache was removed.protected voidremoveShutdownHook()voidrewireNamedRegistries()voidunregisterNamedComponentRegistry(java.lang.String name)-
Methods inherited from class org.infinispan.factories.AbstractComponentRegistry
clone, createComponentFactoryInternal, getComponent, getComponent, getComponent, getComponent, getComponent, getFactory, getOptionalComponent, getOrCreateComponent, getOrCreateComponent, getOrCreateComponent, getRegisteredComponents, getStatus, lookupComponent, registerComponent, registerComponent, registerComponent, registerComponentInternal, registerDefaultClassLoader, registerNonVolatileComponent, registerNonVolatileComponent, registerNullComponent, resetVolatileComponents, rewire, start, stop, throwStackAwareConfigurationException, wireDependencies
-
-
-
-
Constructor Detail
-
GlobalComponentRegistry
public GlobalComponentRegistry(GlobalConfiguration configuration, EmbeddedCacheManager cacheManager, java.util.Set<java.lang.String> createdCaches, ModuleRepository moduleRepository)
Creates an instance of the component registry. The configuration passed in is automatically registered.- Parameters:
configuration- configuration with which this is created
-
-
Method Detail
-
getClassLoader
protected java.lang.ClassLoader getClassLoader()
- Specified by:
getClassLoaderin classAbstractComponentRegistry
-
getLog
protected org.infinispan.util.logging.Log getLog()
- Specified by:
getLogin classAbstractComponentRegistry
-
getComponentMetadataRepo
@Deprecated public ComponentMetadataRepo getComponentMetadataRepo()
Deprecated.Since 10.0, the component metadata repository is empty and no longer used.- Specified by:
getComponentMetadataRepoin classAbstractComponentRegistry
-
removeShutdownHook
protected void removeShutdownHook()
- Overrides:
removeShutdownHookin classAbstractComponentRegistry
-
getTimeService
public TimeService getTimeService()
- Specified by:
getTimeServicein classAbstractComponentRegistry
-
addShutdownHook
protected void addShutdownHook()
- Overrides:
addShutdownHookin classAbstractComponentRegistry
-
getNamedComponentRegistry
public final ComponentRegistry getNamedComponentRegistry(java.lang.String name)
-
getNamedComponentRegistry
public final ComponentRegistry getNamedComponentRegistry(ByteString name)
-
registerNamedComponentRegistry
public final void registerNamedComponentRegistry(ComponentRegistry componentRegistry, java.lang.String name)
-
unregisterNamedComponentRegistry
public final void unregisterNamedComponentRegistry(java.lang.String name)
-
rewireNamedRegistries
public final void rewireNamedRegistries()
-
getModuleCommandInitializers
public java.util.Map<java.lang.Byte,org.infinispan.commands.module.ModuleCommandInitializer> getModuleCommandInitializers()
-
preStart
protected void preStart()
- Specified by:
preStartin classAbstractComponentRegistry
-
postStart
protected void postStart()
- Specified by:
postStartin classAbstractComponentRegistry
-
preStop
protected void preStop()
- Specified by:
preStopin classAbstractComponentRegistry
-
postStop
protected void postStop()
- Specified by:
postStopin classAbstractComponentRegistry
-
notifyCacheStarted
public void notifyCacheStarted(java.lang.String cacheName)
-
getGlobalConfiguration
public final GlobalConfiguration getGlobalConfiguration()
-
removeCache
public boolean removeCache(java.lang.String cacheName)
Removes a cache with the given name, returning true if the cache was removed.
-
getModuleProperties
public ModuleProperties getModuleProperties()
-
getCacheManager
public EmbeddedCacheManager getCacheManager()
-
-