Class EdalServer
- java.lang.Object
-
- de.ipk_gatersleben.bit.bi.edal.rmi.server.EdalServer
-
public class EdalServer extends java.lang.ObjectImplementation of a RMI server for the eDAL system.
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringDATA_MANAGER_NAMEThe name of the eDAL RMI servicestatic intDEFAULT_DATA_PORTstatic intDEFAULT_REGISTRY_PORT
-
Constructor Summary
Constructors Constructor Description EdalServer()
-
Method Summary
Modifier and Type Method Description static org.apache.logging.log4j.LoggergetLogger()static voidmain(java.lang.String[] args)Main function to start the RMI serverstartServer(EdalConfiguration, int, int, boolean, boolean)static voidstartServer(EdalConfiguration config, int registryPort, int dataPort, boolean cleanDB, boolean startLogging)Start the RMI server.static voidstopServer(java.lang.String host, int port)Stop a running eDAL RMI server.
-
-
-
Field Detail
-
DEFAULT_REGISTRY_PORT
public static final int DEFAULT_REGISTRY_PORT
- See Also:
- Constant Field Values
-
DEFAULT_DATA_PORT
public static final int DEFAULT_DATA_PORT
- See Also:
- Constant Field Values
-
DATA_MANAGER_NAME
public static final java.lang.String DATA_MANAGER_NAME
The name of the eDAL RMI service- See Also:
- Constant Field Values
-
-
Method Detail
-
main
public static void main(java.lang.String[] args) throws EdalException, EdalConfigurationExceptionMain function to start the RMI serverstartServer(EdalConfiguration, int, int, boolean, boolean)- Parameters:
args- an array ofStringobjects.- Throws:
EdalException- if failedEdalConfigurationException- if configuration si invalid
-
startServer
public static void startServer(EdalConfiguration config, int registryPort, int dataPort, boolean cleanDB, boolean startLogging)
Start the RMI server.- Parameters:
config- the configuration class to star eDal systemregistryPort- the port to startRegistrydataPort- the data port for RMIcleanDB-true: TAKE CARE!! if the mount path exist; the existing database and index files will be dropped!!
false: mount to existing mount pathstartLogging-true: print out server log to System.out.
false: no output of server log.
-
stopServer
public static void stopServer(java.lang.String host, int port) throws java.rmi.RemoteExceptionStop a running eDAL RMI server.- Parameters:
host- the host to stop theRegistry.port- the port to stop theRegistry.- Throws:
java.rmi.RemoteException- if unable to call remote function.
-
getLogger
public static org.apache.logging.log4j.Logger getLogger()
-
-