|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface NameServer
This is the global naming service's interface.
It provides the means for locating replication group leaders.
Field Summary | |
---|---|
static int |
DEFAULT_PORT_NB
The port number of the location of the centralized name server. |
static java.lang.String |
DEFAULT_URL
The URL of the location of the centralized name server. |
static java.lang.String |
SERVICE_NAME
The RMI identifier of the centralized name server. |
Method Summary | |
---|---|
ReplicantInfo |
getLeaderOfTask(java.lang.String task_name)
Returns the information necessary for obtaining the handle of the current leader of the given replication group. |
void |
register(ReplicantInfo new_replicant)
Registers the info concerning a new replicant for a given task. |
ReplicantInfo |
selectAnotherLeader(ReplicantInfo old_leader)
Selects a replicant as the new leader within its replication group info. |
void |
setLeaderOfTask(ReplicantInfo rep_info)
Selects a replicant as the new leader within its replication group info. |
ReplicantInfo |
setLeaderOfTask(java.lang.String url,
int port_nb,
java.lang.String task_name)
Selects a replicant as the new leader within its replication group info. |
ReplicantInfo |
unregister(java.lang.String task_name,
java.lang.String url,
int port_nb)
Removes the info concerning a replicant for a given task. |
ReplicationGroupInfo |
unregisterGroup(java.lang.String task_name)
Removes the info concerning a whole replication group for a given task. |
Field Detail |
---|
static final java.lang.String DEFAULT_URL
static final int DEFAULT_PORT_NB
static final java.lang.String SERVICE_NAME
Method Detail |
---|
ReplicantInfo getLeaderOfTask(java.lang.String task_name) throws java.rmi.RemoteException, NoMoreReplicantsException, InexistentNameException
task_name
- the generic task name
java.rmi.RemoteException
NoMoreReplicantsException
InexistentNameException
ReplicantInfo selectAnotherLeader(ReplicantInfo old_leader) throws java.rmi.RemoteException, NoMoreReplicantsException, InexistentNameException
old_leader
- the info defining the leader to be replaced
java.rmi.RemoteException
NoMoreReplicantsException
InexistentNameException
void setLeaderOfTask(ReplicantInfo rep_info) throws InexistentNameException, java.rmi.RemoteException, UnknownReplicantException
rep_info
- the info concerning the replicant to be set as the new leader
InexistentNameException
java.rmi.RemoteException
UnknownReplicantException
ReplicantInfo setLeaderOfTask(java.lang.String url, int port_nb, java.lang.String task_name) throws InexistentNameException, java.rmi.RemoteException, UnknownReplicantException
url
- the host of the replicant to be set as new leaderport_nb
- the port nb of the replicant to be set as new leadertask_name
- the generic name of the concerned task
InexistentNameException
java.rmi.RemoteException
UnknownReplicantException
void register(ReplicantInfo new_replicant) throws java.rmi.RemoteException, InexistentNameException
new_replicant
- the replicant info to register
java.rmi.RemoteException
InexistentNameException
ReplicantInfo unregister(java.lang.String task_name, java.lang.String url, int port_nb) throws java.rmi.RemoteException, UnknownReplicantException, InexistentNameException
task_name
- the name of the task to which the replicant belongsurl
- the url of the server hosting the doomed replicaport_nb
- the port nb of the server hosting the doomed replica
java.rmi.RemoteException
UnknownReplicantException
InexistentNameException
ReplicationGroupInfo unregisterGroup(java.lang.String task_name) throws java.rmi.RemoteException, InexistentNameException
task_name
- the name of the task being stopped
java.rmi.RemoteException
InexistentNameException
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |