All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class magician.Four11.Four11

java.lang.Object
   |
   +----magician.Four11.Four11

public class Four11
extends Object
The Four11 Server module. The server is started on the server machine and it listens in on the port given in the configuration file "Four11.conf" for new connections. Clients are expected to use the Four11Stub module to connect to the server. The Four11Stub module sets up the socket streams and provides primitives to send and receive database information in the form of strings. The client is expected to parse the reply to obtain the necessary information An example of using the service is given below.

...
Four11Stub netInfo = new Four11Stub();
String nbors = netInfo.send("(net: KUNet (node: wigner nbors: *)");
// the '*' indicates the information sought. Please make sure
// that the property name ends with ':' and is separated from
// the property value by a whitespace (i.e. a space, newline or
// tab).

// to disconnect use
netInfo.send("(disconnect)");

See Also:
Four11Stub

Constructor Index

 o Four11()

Method Index

 o main(String[])
The Four11 server takes the name of a network configuration file as an argument.

Constructors

 o Four11
 public Four11()

Methods

 o main
 public static void main(String argv[])
The Four11 server takes the name of a network configuration file as an argument. On startup the Four11 server reads a Four11 setup configuration file to determine the port on which active nodes will attempt to connect to it. The setup configuration file is named Four11.conf and must be identical at all active nodes and the Four11 server. The Four11 server then creates a in-memory copy of the network topology using the information from the network configuration file. The server then waits for active nodes to connect. When an active node makes a request, a separate thread is started that handles its query.

See Also:
MessageHandler

All Packages  Class Hierarchy  This Package  Previous  Next  Index
1