summaryrefslogtreecommitdiff
path: root/same/src/main
diff options
context:
space:
mode:
Diffstat (limited to 'same/src/main')
-rw-r--r--same/src/main/java/com/orbekk/same/DirectoryApp.java2
-rw-r--r--same/src/main/java/com/orbekk/same/Master.java1
-rw-r--r--same/src/main/java/com/orbekk/same/SameController.java6
3 files changed, 6 insertions, 3 deletions
diff --git a/same/src/main/java/com/orbekk/same/DirectoryApp.java b/same/src/main/java/com/orbekk/same/DirectoryApp.java
index 08c3cc5..ceca49d 100644
--- a/same/src/main/java/com/orbekk/same/DirectoryApp.java
+++ b/same/src/main/java/com/orbekk/same/DirectoryApp.java
@@ -31,7 +31,7 @@ public class DirectoryApp {
final Rpc rpc = new Rpc();
MasterState request = MasterState.newBuilder()
.setNetworkName("Test network")
- .setMasterUrl("invalid:invalid")
+ .setMasterLocation("invalid:invalid")
.build();
RpcCallback<Empty> done = new RpcCallback<Empty>() {
@Override public void run(Empty unused) {
diff --git a/same/src/main/java/com/orbekk/same/Master.java b/same/src/main/java/com/orbekk/same/Master.java
index c83d4a6..fb3306e 100644
--- a/same/src/main/java/com/orbekk/same/Master.java
+++ b/same/src/main/java/com/orbekk/same/Master.java
@@ -93,7 +93,6 @@ public class Master {
done.run(Empty.getDefaultInstance());
}
-
@Override public void updateStateRequest(RpcController controller,
Services.Component request,
RpcCallback<Services.UpdateComponentResponse> done) {
diff --git a/same/src/main/java/com/orbekk/same/SameController.java b/same/src/main/java/com/orbekk/same/SameController.java
index c44d3bb..a16f57a 100644
--- a/same/src/main/java/com/orbekk/same/SameController.java
+++ b/same/src/main/java/com/orbekk/same/SameController.java
@@ -79,6 +79,7 @@ public class SameController {
.build();
SimpleProtobufServer pServer = SimpleProtobufServer.create(pport);
+ pServer.registerService(client.getNewService());
SameController controller = new SameController(
configuration, connections, server, master, client,
@@ -153,6 +154,10 @@ public class SameController {
return master;
}
+ public void registerCurrentNetwork() {
+ registerNetwork(master);
+ }
+
public void registerNetwork(Master master) {
Services.Directory directory = getDirectory();
if (directory == null) {
@@ -160,7 +165,6 @@ public class SameController {
}
Services.MasterState request = Services.MasterState.newBuilder()
.setNetworkName(master.getNetworkName())
- .setMasterUrl(master.getUrl())
.setMasterLocation(master.getLocation())
.build();
final Rpc rpc = new Rpc();