public class CachedJndiNameResolver extends AbstractJndiNameResolver
JndiNameResolver that uses a cache in order to store
the already resolved names.
The cache does not have an automated mechanism for cleaning up the data.
In case of getting corrupt data, a way to cleaning up the cache is to stop
and then restart the instance.| Modifier and Type | Field and Description |
|---|---|
protected Map<String,Object> |
cache |
logger| Constructor and Description |
|---|
CachedJndiNameResolver() |
| Modifier and Type | Method and Description |
|---|---|
void |
initialise() |
Object |
lookup(String name)
Looks up an object by name.
|
void |
stop()
Cleans up the cache.
|
createInitialContext, dispose, getContextFactory, getContextProperties, getJndiInitialFactory, getJndiProviderProperties, getJndiProviderUrl, setContextFactory, setJndiInitialFactory, setJndiProviderProperties, setJndiProviderUrl, startpublic Object lookup(String name) throws NamingException
JndiNameResolvername - the name of the object to search forNamingException - is there is an error during the lookup.public void initialise()
initialise in interface org.mule.api.lifecycle.Initialisableinitialise in class AbstractJndiNameResolverpublic void stop()
throws org.mule.api.MuleException
stop in interface org.mule.api.lifecycle.Stoppablestop in class AbstractJndiNameResolverorg.mule.api.MuleExceptionCopyright © 2003–2016 MuleSoft, Inc.. All rights reserved.