next up previous contents
Next: The Client Up: The Server Previous: ServerConnection   Contents

GossipServer

Server to server interaction was tested by copying the binary to several machines on the Cambridge network and then setting up their configuration files so they could find at least one of the other servers. A server's behaviour was observed by printing useful information to STDOUT and STDERR.

Making a server connect to the server-network tested most of the server-server related functions. The remaining ones were tested by simulating a host going down by terminating the server process. A network partition was simulated by starting two independent server networks. The remote administration interface was then used to join them together, verifying the operation by observing output to STDOUT.

Figure 4.1: The three-server test case
\includegraphics[width=\textwidth]{graphics/3server1.eps}

One critical test case for the server connectivity was the three server case, when two servers are connected to the third (and not each other). The middle server was taken down and as expected the other two servers attempted to connect to each other. Unfortunately both servers succeeded in connecting to the other, resulting in the situation shown in in figure 4.1(b).

This problem was resolved by making the server check whether it already had a connection to that server before initiating or accepting a connection. Concurrency control was also added to prevent two threads attempting to make modifications to the set of ServerConnection pointers at the same time.


next up previous contents
Next: The Client Up: The Server Previous: ServerConnection   Contents
Nathan Dimmock 2001-06-20