ParkNPark.interfaces
Interface ClientManagerFactoryOperations

All Known Subinterfaces:
ClientManagerFactory
All Known Implementing Classes:
_ClientManagerFactoryStub, ClientManagerFactoryImpl, ClientManagerFactoryPOA

public interface ClientManagerFactoryOperations

The main interface that the client uses to communicate with the server


Method Summary
 ClientManager getClientManager(String hostname)
          Creates a new client manager instance for a new client
 ClientManager getExistingClientManager(int clientID, String hostname)
          Returns the existing client manager instance for an existing client.
 void hoseDatabaseConnection()
          Causes the server's database connection to become "hosed," meaning that it will fail to work after this method is called.
 void poke()
          Pokes the server to see if it is still alive and that it can still communicate with the database
 

Method Detail

getClientManager

ClientManager getClientManager(String hostname)
                               throws ServiceUnavailableException
Creates a new client manager instance for a new client

Parameters:
hostname - The host name of the client
Returns:
A new client manager instance for a new client [Category: Dependability; Requirement: not set yet]
Throws:
ServiceUnavailableException - Thrown if the database cannot be contacted or if some other reason prevents the client manager from being created successfully

getExistingClientManager

ClientManager getExistingClientManager(int clientID,
                                       String hostname)
                                       throws ServiceUnavailableException,
                                              InvalidClientException
Returns the existing client manager instance for an existing client. A client can call this method with its client ID and last sequence number on any server and should get its client manager instance

Parameters:
clientID - The ID of the client to get the ClientManager of
hostname - The host name of the client
Returns:
The existing client manager instance for an existing client [Category: Dependability; Requirement: not set yet]
Throws:
InvalidClientException - Thrown when the given client ID is not known to the system
ServiceUnavailableException - Thrown if the database cannot be contacted or if some other reason prevents the client manager from being retrieved successfully

poke

void poke()
          throws ServiceUnavailableException
Pokes the server to see if it is still alive and that it can still communicate with the database

Throws:
ServiceUnavailableException - Thrown when the server's database connection is not working

hoseDatabaseConnection

void hoseDatabaseConnection()
Causes the server's database connection to become "hosed," meaning that it will fail to work after this method is called. This is used primarily for fault injection