universal
Class UniversalCrashStop

java.lang.Object
  |
  +--universal.Universal
        |
        +--universal.UniversalCrashStop

public class UniversalCrashStop
extends Universal

This subclass of Universal implements the crash stop model in the server side

It is instantiated by the aplication server.
Crash Stop Model means once a server has crashed it never recovers
It instantiates the object LeaderCrashStopServer useful for the leader election part.
It also instantiates the object Register that is for the consensus purposes.


Field Summary
 
Fields inherited from class universal.Universal
add, add1, cons, lead, pid, port, receiver, reg, replicasAnnounce, replicasNameFile, sender, serverSocket, t, totalDel, waiting
 
Constructor Summary
UniversalCrashStop(int pid, java.lang.String replicasNameFile)
          Each replicated servers instantiate one object UniversalCrashStop.
 
Method Summary
 void initializeTasks()
          Instantiate the object LeaderCrashStopserver (useful for the leader election) Instantiate the object Register (useful for the consensus)
 
Methods inherited from class universal.Universal
initializeUniversal, startTasks, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

UniversalCrashStop

public UniversalCrashStop(int pid,
                          java.lang.String replicasNameFile)
Each replicated servers instantiate one object UniversalCrashStop.
call the constructor of its superclass
Call different method of its superclass universal in order to intialize
our infrastructure (instantiate some object, start some thread ).

Parameters:
pid - the pid of the replicated server which instantiates it.
replicasNameFile - the name of the file which contains the list of all the others replicated server and their pid.
Method Detail

initializeTasks

public void initializeTasks()
Instantiate the object LeaderCrashStopserver (useful for the leader election) Instantiate the object Register (useful for the consensus)

Specified by:
initializeTasks in class Universal