|
|||||||||
| Home >> All >> org >> [ mule overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
org.mule
Class MuleManager

java.lang.Objectorg.mule.MuleManager
- All Implemented Interfaces:
- MuleConstants
- public class MuleManager
- extends java.lang.Object
- implements MuleConstants
- extends java.lang.Object
MuleManager maintains and provides services for a Mule instance.
All mules and tranformations are registered in the MuleManager. The Transaction
Manager and performance metric helpers is also accessible from here.
The developer can use the Mulemanager to stop start or pause all or any specific mules
in the system.
- Version:
- $Revision: 1.2 $
| Field Summary | |
private MuleConfiguration |
config
Default configuration |
private java.util.Map |
connectors
Connectors registry |
private java.util.Map |
endpoints
Endpoints registry |
private static boolean |
initialised
True once the Mule Manager is initialised |
private static MuleManager |
instance
singleton instance |
private static org.apache.commons.logging.Log |
log
logger used by this class |
private java.util.Map |
props
Holds any environment properties set in the config |
private org.mule.umo.impl.ProviderList |
providers
Holds a list of global providers accessible to any client code |
private static MuleServer |
server
Holds a reference to the deamon running the Manager if any |
private org.mule.umo.impl.MuleSessionManager |
sessionManager
holds a reference to the session manager instance |
private java.util.HashMap |
transformers
Collection for transformers registered in this session |
| Fields inherited from interface org.mule.MuleConstants |
JNDI_CONNECTION_FACTORY_NAME, JNDI_NAMING_FACTORY_INITIAL, JNDI_NAMING_PROVIDER, MULE_PROPERTY_PROPERTY_FILE, PROPERTY_ID, PROPERTY_PREFIX |
| Constructor Summary | |
private |
MuleManager()
Default Constructor |
| Method Summary | |
static void |
configure(java.lang.String xmlURL)
A helper method to explicitly configure the CacheManager singleton from a given XML deployment configuration document |
static void |
configure(java.lang.String xmlURL,
MuleServer muleServer)
A helper method to explicitly configure the CacheManager singleton from a given XML deployment configuration document |
protected static MuleManager |
createInstance()
Factory method to create the singleton MuleManager instance |
void |
destroy()
Destroys the MuleManager and all resources it maintains |
private void |
destroyConnectors()
Destroys all connectors |
void |
dispatch(java.lang.String muleName,
org.mule.umo.UMOEvent event)
|
MuleConfiguration |
getConfiguration()
|
static MuleManager |
getInstance()
Getter method for the current singleton MuleManager |
java.lang.Object |
getProperty(java.lang.Object key)
Getter for the envionment parameters declared in the nule-config.xml |
java.util.Iterator |
getPropertyNames()
|
org.mule.umo.UMOSession |
getSession(java.lang.String muleName)
A convenience method to get a session from the session manager |
org.mule.umo.UMOSession |
getSession(org.mule.umo.UMODescriptor descriptor)
A convenience method to get a session from the session manager |
org.mule.umo.impl.MuleSessionManager |
getSessionManager()
A convenience method to obtain a reference to the Session Manager |
boolean |
isMuleRegistered(java.lang.String name)
|
static MuleManager |
load(java.lang.String url)
A helper method to load the MuleManager from a given XML deployment configuration document |
org.mule.umo.provider.UMOConnector |
lookupConnector(java.lang.String logicalName)
|
java.lang.String |
lookupEndpoint(java.lang.String logicalName)
|
org.mule.umo.impl.MuleProviderDescriptor |
lookupProvider(java.lang.String logicalName)
Getter for a global provider. |
org.mule.umo.transformer.UMOTransformer |
lookupTransformer(java.lang.String name)
Getter method for a Transformer. |
void |
registerConnector(org.mule.umo.provider.UMOConnector connector)
Registers a UMOConnector with the MuleManager. |
void |
registerEndpoint(java.lang.String logicalName,
java.lang.String endpoint)
Registers an endpoint with a logical name |
void |
registerMule(org.mule.umo.UMODescriptor muleDescriptor)
Registers a UMODescriptor with the MuleManager. |
void |
registerProvider(org.mule.umo.impl.MuleProviderDescriptor provider)
Registers a shared/global provider with the MuleManager. |
void |
registerTransformer(org.mule.umo.transformer.UMOTransformer transformer)
Registers a transformer with the MuleManager. |
void |
setConfiguration(MuleConfiguration config)
Sets the configuration for the MuleManager. |
void |
setProperty(java.lang.Object key,
java.lang.Object value)
Sets an Mule environment parameter in the MuleManager. |
(package private) void |
setServer(MuleServer server)
If the MuleManager was started from the MuleServer
daemon then this will be called by the Server |
void |
shutdown(java.lang.Throwable e)
Shuts down the whole server tring to shut down all resources cleanly on the way |
void |
start()
Start the MuleManager. |
private void |
startConnectors()
Starts the connectors |
void |
startMule(java.lang.String name)
Starts a single Mule. |
void |
stop()
Stops the MuleManager which stops all sessions and connectors |
private void |
stopConnectors()
Stops the connectors |
void |
stopMule(java.lang.String name)
Stops a single Mule. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
instance
private static MuleManager instance
- singleton instance
sessionManager
private org.mule.umo.impl.MuleSessionManager sessionManager
- holds a reference to the session manager instance
config
private MuleConfiguration config
- Default configuration
connectors
private java.util.Map connectors
- Connectors registry
endpoints
private java.util.Map endpoints
- Endpoints registry
props
private java.util.Map props
- Holds any environment properties set in the config
providers
private org.mule.umo.impl.ProviderList providers
- Holds a list of global providers accessible to any client code
transformers
private java.util.HashMap transformers
- Collection for transformers registered in this session
initialised
private static boolean initialised
- True once the Mule Manager is initialised
server
private static MuleServer server
- Holds a reference to the deamon running the Manager if any
log
private static transient org.apache.commons.logging.Log log
- logger used by this class
| Constructor Detail |
MuleManager
private MuleManager()
- Default Constructor
| Method Detail |
configure
public static void configure(java.lang.String xmlURL) throws java.io.IOException, org.xml.sax.SAXException
- A helper method to explicitly configure the CacheManager singleton
from a given XML deployment configuration document
configure
public static void configure(java.lang.String xmlURL, MuleServer muleServer) throws java.io.IOException, org.xml.sax.SAXException
- A helper method to explicitly configure the CacheManager singleton
from a given XML deployment configuration document
createInstance
protected static MuleManager createInstance()
- Factory method to create the singleton MuleManager instance
getInstance
public static MuleManager getInstance()
- Getter method for the current singleton MuleManager
load
public static MuleManager load(java.lang.String url) throws java.io.IOException, org.xml.sax.SAXException
- A helper method to load the MuleManager
from a given XML deployment configuration document
destroy
public void destroy()
throws org.mule.umo.UMOException
- Destroys the MuleManager and all resources it maintains
destroyConnectors
private void destroyConnectors()
- Destroys all connectors
getConfiguration
public MuleConfiguration getConfiguration()
getProperty
public java.lang.Object getProperty(java.lang.Object key)
- Getter for the envionment parameters declared in the nule-config.xml
getPropertyNames
public java.util.Iterator getPropertyNames()
isMuleRegistered
public boolean isMuleRegistered(java.lang.String name)
lookupConnector
public org.mule.umo.provider.UMOConnector lookupConnector(java.lang.String logicalName) throws MuleException
lookupEndpoint
public java.lang.String lookupEndpoint(java.lang.String logicalName)
lookupProvider
public org.mule.umo.impl.MuleProviderDescriptor lookupProvider(java.lang.String logicalName)
- Getter for a global provider. Any providers returned from this method
will be read-only as they may be shared by other components. To change
any details on the provider you must clone it first calling it's clone() method
dispatch
public void dispatch(java.lang.String muleName, org.mule.umo.UMOEvent event) throws org.mule.umo.UMOException
lookupTransformer
public org.mule.umo.transformer.UMOTransformer lookupTransformer(java.lang.String name)
- Getter method for a Transformer.
registerConnector
public void registerConnector(org.mule.umo.provider.UMOConnector connector)
- Registers a
UMOConnectorwith theMuleManager.
registerEndpoint
public void registerEndpoint(java.lang.String logicalName, java.lang.String endpoint)
- Registers an endpoint with a logical name
registerMule
public void registerMule(org.mule.umo.UMODescriptor muleDescriptor) throws org.mule.umo.UMOException
- Registers a
UMODescriptorwith theMuleManager. The manager will take care of creating the Mule UMO and, it's session and proxies.
registerProvider
public void registerProvider(org.mule.umo.impl.MuleProviderDescriptor provider)
- Registers a shared/global provider with the
MuleManager.
registerTransformer
public void registerTransformer(org.mule.umo.transformer.UMOTransformer transformer)
- Registers a transformer with the
MuleManager.
setConfiguration
public void setConfiguration(MuleConfiguration config)
- Sets the configuration for the
MuleManager.
setProperty
public void setProperty(java.lang.Object key, java.lang.Object value)
- Sets an Mule environment parameter in the
MuleManager.
start
public void start()
throws org.mule.umo.UMOException
- Start the
MuleManager. This will start the connectors and sessions.
startConnectors
private void startConnectors()
throws MuleException
- Starts the connectors
startMule
public void startMule(java.lang.String name) throws org.mule.umo.UMOException
- Starts a single Mule. This can be useful when stopping and starting some
Mule UMOs while letting others continue
stop
public void stop()
throws org.mule.umo.UMOException
- Stops the
MuleManagerwhich stops all sessions and connectors
stopConnectors
private void stopConnectors()
throws MuleException
- Stops the connectors
stopMule
public void stopMule(java.lang.String name) throws org.mule.umo.UMOException
- Stops a single Mule. This can be useful when stopping and starting some
Mule UMOs while letting others continue.
setServer
void setServer(MuleServer server)
- If the
MuleManagerwas started from theMuleServerdaemon then this will be called by the Server
shutdown
public void shutdown(java.lang.Throwable e)
- Shuts down the whole server tring to shut down all resources cleanly on the way
getSessionManager
public org.mule.umo.impl.MuleSessionManager getSessionManager()
- A convenience method to obtain a reference to the Session Manager
getSession
public org.mule.umo.UMOSession getSession(java.lang.String muleName) throws org.mule.umo.UMOException
- A convenience method to get a session from the session manager
getSession
public org.mule.umo.UMOSession getSession(org.mule.umo.UMODescriptor descriptor) throws org.mule.umo.UMOException
- A convenience method to get a session from the session manager
|
|||||||||
| Home >> All >> org >> [ mule overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC
org.mule.MuleManager