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/App.java (renamed from same/src/main/java/com/orbekk/same/MasterApp.java)16
-rw-r--r--same/src/main/resources/master.properties.example1
2 files changed, 8 insertions, 9 deletions
diff --git a/same/src/main/java/com/orbekk/same/MasterApp.java b/same/src/main/java/com/orbekk/same/App.java
index c5e270a..2416899 100644
--- a/same/src/main/java/com/orbekk/same/MasterApp.java
+++ b/same/src/main/java/com/orbekk/same/App.java
@@ -1,27 +1,25 @@
package com.orbekk.same;
-import org.eclipse.jetty.server.Server;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
-import com.googlecode.jsonrpc4j.JsonRpcServer;
import com.orbekk.same.config.Configuration;
-public class MasterApp {
+public class App {
private Logger logger = LoggerFactory.getLogger(getClass());
-
- public void run(Configuration configuration) {
+
+ public void run(String[] args) {
+ Configuration configuration = Configuration.loadOrDie();
SameController controller = SameController.create(configuration);
try {
controller.start();
+ controller.join();
} catch (Exception e) {
- logger.error("Failed to start Same", e);
+ logger.error("Error in App.", e);
}
- controller.join();
}
public static void main(String[] args) {
- Configuration configuration = Configuration.loadOrDie();
- (new MasterApp()).run(configuration);
+ new App().run(args);
}
}
diff --git a/same/src/main/resources/master.properties.example b/same/src/main/resources/master.properties.example
index 338d6a9..f168f2c 100644
--- a/same/src/main/resources/master.properties.example
+++ b/same/src/main/resources/master.properties.example
@@ -1 +1,2 @@
port=10010
+localIp=10.0.0.6