Skip to content
Snippets Groups Projects

Added tell supervisor action to make system init work

Merged davbohn requested to merge dev-group3-supervisor-fix into dev-group3
9 files
+ 63
32
Compare changes
  • Side-by-side
  • Inline
Files
9
@@ -14,8 +14,14 @@ public class ActionJoin extends ClientAction {
@@ -14,8 +14,14 @@ public class ActionJoin extends ClientAction {
protected void onAction(ActorRef sender, ActorRef self, UntypedActorContext context, AbstractWallet node) {
protected void onAction(ActorRef sender, ActorRef self, UntypedActorContext context, AbstractWallet node) {
// send the joined node all known neighbours from node and a reference to the supervisor
// send the joined node all known neighbours from node and a reference to the supervisor
ActionJoinAnswer aja = new ActionJoinAnswer(node.resolveSuperVisorActor());
ActionJoinAnswer aja = new ActionJoinAnswer();
aja.someNeighbors.putAll(node.getKnownNeighbors());
aja.someNeighbors.putAll(node.getKnownNeighbors());
sender.tell(aja, self);
sender.tell(aja, self);
 
 
if (node.getRemoteSuperVisorActor() == null) {
 
node.deferSendOfSuperVisorActor(sender);
 
} else {
 
sender.tell(new ActionTellSupervisor(node.getRemoteSuperVisorActor()), self);
 
}
}
}
}
}
Loading