|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.modeshape.connector.infinispan.BaseInfinispanSource
org.modeshape.connector.infinispan.InfinispanSource
@ThreadSafe public class InfinispanSource
A repository source that uses an Infinispan instance to manage the content. This source is capable of using an existing
CacheContainer
or creating a new cache container. This process is controlled entirely by the JavaBean properties of the
InfinispanSource instance.
This source first attempts to find an existing cache manager found in JNDI
(or the
DefaultCacheManager
if no such manager is available) and the cache configuration
name
if supplied or the default configuration if not set.
Like other RepositorySource
classes, instances of InfinispanCacheSource can be placed into JNDI and do support the
creation of JNDI referenceable
objects and resolution of references into JBossCacheSource.
Field Summary | |
---|---|
protected static String |
CACHE_CONFIGURATION_NAME
|
protected static String |
CACHE_FACTORY_JNDI_NAME
|
Fields inherited from class org.modeshape.connector.infinispan.BaseInfinispanSource |
---|
ALLOW_CREATING_WORKSPACES, DEFAULT_CACHE_POLICY, DEFAULT_NAME_OF_DEFAULT_WORKSPACE, DEFAULT_RETRY_LIMIT, DEFAULT_ROOT_NODE_UUID, DEFAULT_UPDATES_ALLOWED, DEFAULT_WORKSPACE, PREDEFINED_WORKSPACE_NAMES, RETRY_LIMIT, ROOT_NODE_UUID, SOURCE_NAME, UPDATES_ALLOWED |
Constructor Summary | |
---|---|
InfinispanSource()
Create a repository source instance. |
Method Summary | |
---|---|
protected org.infinispan.manager.CacheContainer |
createCacheContainer()
Method controls how a cache container gets created. |
boolean |
equals(Object obj)
|
String |
getCacheConfigurationName()
Get the name of the configuration that should be used if a cache is to be created using the
CacheContainer found in JNDI or the DefaultCacheManager if needed. |
String |
getCacheContainerJndiName()
Get the name in JNDI of a CacheContainer instance that should be used to create the cache for this source. |
String |
getCacheManagerJndiName()
Deprecated. |
Object |
getObjectInstance(Object obj,
Name name,
Context nameCtx,
Hashtable<?,?> environment)
|
Reference |
getReference()
|
int |
hashCode()
|
void |
setCacheConfigurationName(String cacheConfigurationName)
Get the name of the configuration that should be used if a cache is to be created using the
CacheContainer found in JNDI or the DefaultCacheManager if needed. |
void |
setCacheContainerJndiName(String jndiName)
Set the name in JNDI of a CacheContainer instance that should be used to obtain the Cache instance used by
this source. |
void |
setCacheManagerJndiName(String jndiName)
Deprecated. |
Methods inherited from class org.modeshape.connector.infinispan.BaseInfinispanSource |
---|
areUpdatesAllowed, close, getCapabilities, getConnection, getContext, getDefaultCachePolicy, getDefaultWorkspaceName, getName, getObserver, getPredefinedWorkspaceNames, getRepositoryContext, getRetryLimit, getRootNodeUuid, getRootNodeUuidObject, initialize, isCreatingWorkspacesAllowed, setContext, setCreatingWorkspacesAllowed, setDefaultCachePolicy, setDefaultWorkspaceName, setName, setPredefinedWorkspaceNames, setRetryLimit, setRootNodeUuid, setUpdatesAllowed |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static final String CACHE_CONFIGURATION_NAME
protected static final String CACHE_FACTORY_JNDI_NAME
Constructor Detail |
---|
public InfinispanSource()
Method Detail |
---|
public String getCacheContainerJndiName()
CacheContainer
instance that should be used to create the cache for this source.
This source first attempts to find a cache instance using the CacheContainer
found in
JNDI
(or the DefaultCacheManager
if no such manager is available) and the
cache configuration name
if supplied or the default configuration if not set.
CacheContainer
instance that should be used, or null if the
DefaultCacheManager
should be used if a cache is to be createdsetCacheContainerJndiName(String)
,
getCacheConfigurationName()
public void setCacheContainerJndiName(String jndiName)
CacheContainer
instance that should be used to obtain the Cache
instance used by
this source.
This source first attempts to find a cache instance using the CacheContainer
found in
JNDI
(or the DefaultCacheManager
if no such manager is available) and the
cache configuration name
if supplied or the default configuration if not set.
jndiName
- the JNDI name of the CacheContainer
instance that should be used, or null if the
DefaultCacheManager
should be used if a cache is to be createdsetCacheContainerJndiName(String)
,
getCacheConfigurationName()
@Deprecated public String getCacheManagerJndiName()
@Deprecated public void setCacheManagerJndiName(String jndiName)
public String getCacheConfigurationName()
cache
is to be created using the
CacheContainer
found in JNDI or the DefaultCacheManager
if needed.
This source first attempts to find a cache instance using the CacheContainer
found in
JNDI
(or the DefaultCacheManager
if no such manager is available) and the
cache configuration name
if supplied or the default configuration if not set.
CacheContainer
, or null if the default
configuration should be usedsetCacheConfigurationName(String)
,
getCacheContainerJndiName()
public void setCacheConfigurationName(String cacheConfigurationName)
cache
is to be created using the
CacheContainer
found in JNDI or the DefaultCacheManager
if needed.
This source first attempts to find a cache instance using the CacheContainer
found in
JNDI
(or the DefaultCacheManager
if no such manager is available) and the
cache configuration name
if supplied or the default configuration if not set.
cacheConfigurationName
- the name of the configuration that should be passed to the CacheContainer
, or null if
the default configuration should be usedgetCacheConfigurationName()
,
getCacheContainerJndiName()
protected org.infinispan.manager.CacheContainer createCacheContainer()
BaseInfinispanSource
createCacheContainer
in class BaseInfinispanSource
public boolean equals(Object obj)
equals
in class Object
public int hashCode()
hashCode
in class Object
public Reference getReference()
getReference
in interface Referenceable
getReference
in class BaseInfinispanSource
public Object getObjectInstance(Object obj, Name name, Context nameCtx, Hashtable<?,?> environment) throws Exception
Exception
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |