public class SimpleJndiNameResolver extends AbstractJndiNameResolver
JndiNameResolver
that maintains a Context
instance opened all the time and always relies on the context to do the look
ups.logger
PHASE_NAME
PHASE_NAME
PHASE_NAME
PHASE_NAME
Constructor and Description |
---|
SimpleJndiNameResolver() |
Modifier and Type | Method and Description |
---|---|
void |
dispose()
A lifecycle method where implementor should free up any resources.
|
void |
initialise()
Method used to perform any initialisation work.
|
Object |
lookup(String name)
Looks up an object by name.
|
createInitialContext, getContextFactory, getContextProperties, getJndiInitialFactory, getJndiProviderProperties, getJndiProviderUrl, setContextFactory, setJndiInitialFactory, setJndiProviderProperties, setJndiProviderUrl, start, stop
public Object lookup(String name) throws NamingException
JndiNameResolver
name
- the name of the object to search forNamingException
- is there is an error during the lookup.public void initialise() throws InitialisationException
Initialisable
InitialisationException
should be thrown,
causing the Mule instance to shutdown. If the error is recoverable, say by
retrying to connect, a RecoverableException
should be thrown.
There is no guarantee that by throwing a Recoverable exception that the Mule
instance will not shut down.initialise
in interface Initialisable
initialise
in class AbstractJndiNameResolver
InitialisationException
- if a fatal error occurs causing the Mule instance to shutdownRecoverableException
- if an error occurs that can be recovered frompublic void dispose()
Disposable
dispose
in interface Disposable
dispose
in class AbstractJndiNameResolver
Copyright © 2003–2015 MuleSoft, Inc.. All rights reserved.