// create his list of SuperNode
// containing the IPs and ports
// but not already the stubs
+ if (System.getSecurityManager() == null) {
+ System.setSecurityManager(new SecurityManager());
+ }
+
+
SuperNodeListe.Instance().staticInitialization();
HeartBeatSNode.Instance().setHeartTime(heartTime);
next = index + 1;
HeartBeatSNode.Instance().setServer(
((SuperNodeData) SuperNodeListe.Instance().getListe()
- .elementAt(next)).getStub());
+ .get(next)).getStub());
if (index == 0)
previous = SuperNodeListe.Instance().getListe().size() - 1;
else
previous = index - 1;
System.out.println(index + " " + next + " " + previous);
try {
- ((SuperNodeData) SuperNodeListe.Instance().getListe().elementAt(
+ ((SuperNodeData) SuperNodeListe.Instance().getListe().get(
previous)).getStub().updateHeart(
((SuperNodeData) SuperNodeListe.Instance().getListe()
- .elementAt(index)).getStub());
+ .get(index)).getStub());
} catch (Exception e) {
System.err
SuperNodeListe.Instance().forwardCountNode();
try {
- snodeServer.delGNodeFromList( host, 0 ) ;
+ snodeServer.delGNodeFromList( host, 0, "" ) ;
} catch (RemoteException e) {
System.err.println( "Unable to remove the dead node from the list !" ) ;
e.printStackTrace();