org.mmbase.module
Class RemoteMMCI

java.lang.Object
  extended by org.mmbase.util.functions.FunctionProvider
      extended by org.mmbase.util.functions.DescribedFunctionProvider
          extended by org.mmbase.module.Module
              extended by org.mmbase.module.RemoteMMCI
All Implemented Interfaces:
Descriptor

public class RemoteMMCI
extends Module

RemoteMMCI is a MMBase module that starts a Remote Method Invocation registry and binds a remote MMCI context to the server. Look a rmmci.xml for configuration options. Note that in the configuration of mmbaseroot.xml the host should be a valid host address if the RMIRegistryServer in rmmci.xml is no set.

Since:
MMBase-1.5
Version:
$Id: RemoteMMCI.java 42587 2010-06-17 11:46:57Z jkoster $
Author:
Kees Jongenburger

Nested Class Summary
(package private) static class RemoteMMCI.RemoteChecker
           
 
Field Summary
static String DEFAULT_BIND_NAME
          DEFAULT_BIND_NAME = "remotecontext"
static int DEFAULT_RMIREGISTRY_PORT
          DEFAULT_RMIREGISTRY_PORT = 1111
 
Fields inherited from class org.mmbase.module.Module
configurationPath, getMaintainerFunction, getVersionFunction, properties, STATE_START_TIME
 
Fields inherited from class org.mmbase.util.functions.DescribedFunctionProvider
description, guiName, name
 
Fields inherited from class org.mmbase.util.functions.FunctionProvider
functions, getFunctions
 
Constructor Summary
RemoteMMCI(String name)
           
 
Method Summary
 String getBindName()
           
 String getHost()
           
 String[] getListOfNames(String host, int registryPort)
           
 int getPort()
           
 Registry getRegistry(String host, int registryPort)
           
 void init()
          Method called by MMBase at startup it calls the createRemoteMMCI based on the rmmci.xml configuration
 void register(Registry reg, String bindName)
           
 void resetBind(String host, int registryPort, String bindName)
           
protected  void shutdown()
          unbinds the object bound to the registry in order to try to stop the registry this usualy fails(the registry keeps running and prevents the webapp to shutdown)
 boolean test(String host, int registryPort, String bindName)
           
 
Methods inherited from class org.mmbase.module.Module
addInitParameters, checkModules, getInitParameter, getInitParameter, getInitParameter, getInitParameters, getInitParameters, getMaintainer, getModule, getModule, getModule, getModule, getModuleInfo, getModuleLoader, getModuleReader, getModuleReader, getModules, getState, getStates, getVersion, hasModule, hasStarted, loadInitParameters, loadInitParameters, maintainance, onload, setInitParameter, setMaintainer, setState, setVersion, shutdownModules, startModule, startModules
 
Methods inherited from class org.mmbase.util.functions.DescribedFunctionProvider
getDefaultLocale, getDescription, getDescription, getGUIName, getGUIName, getLocalizedDescription, getLocalizedGUIName, getName, setDescription, setDescription, setGUIName, setGUIName, setLocalizedDescription, setLocalizedGUIName, setName
 
Methods inherited from class org.mmbase.util.functions.FunctionProvider
addFunction, createParameters, getFunction, getFunctions, getFunctionValue, newFunctionInstance
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_RMIREGISTRY_PORT

public static final int DEFAULT_RMIREGISTRY_PORT
DEFAULT_RMIREGISTRY_PORT = 1111

See Also:
Constant Field Values

DEFAULT_BIND_NAME

public static final String DEFAULT_BIND_NAME
DEFAULT_BIND_NAME = "remotecontext"

See Also:
Constant Field Values
Constructor Detail

RemoteMMCI

public RemoteMMCI(String name)
Method Detail

init

public void init()
Method called by MMBase at startup it calls the createRemoteMMCI based on the rmmci.xml configuration

Overrides:
init in class Module

getBindName

public String getBindName()

getHost

public String getHost()

getPort

public int getPort()

getRegistry

public Registry getRegistry(String host,
                            int registryPort)
                     throws RemoteException
Throws:
RemoteException

register

public void register(Registry reg,
                     String bindName)
              throws RemoteException,
                     AccessException
Throws:
RemoteException
AccessException

getListOfNames

public String[] getListOfNames(String host,
                               int registryPort)

shutdown

protected void shutdown()
unbinds the object bound to the registry in order to try to stop the registry this usualy fails(the registry keeps running and prevents the webapp to shutdown)

Overrides:
shutdown in class Module

test

public boolean test(String host,
                    int registryPort,
                    String bindName)

resetBind

public void resetBind(String host,
                      int registryPort,
                      String bindName)
               throws RemoteException,
                      AccessException
Throws:
RemoteException
AccessException


MMBase 2.0-SNAPSHOT - null