summaryrefslogtreecommitdiffstats
path: root/gearman/controllerWorker/ControllerWorker/BootWorker.java
diff options
context:
space:
mode:
authorBjörn Geiger2011-07-27 12:37:37 +0200
committerBjörn Geiger2011-07-27 12:37:37 +0200
commitceaa8457f82107df480e04397aa1f636f55429cb (patch)
tree8f3003bb5e974f5a0985233eccccfdbf60929a14 /gearman/controllerWorker/ControllerWorker/BootWorker.java
parentminor (diff)
downloadpoolctrl-ceaa8457f82107df480e04397aa1f636f55429cb.tar.gz
poolctrl-ceaa8457f82107df480e04397aa1f636f55429cb.tar.xz
poolctrl-ceaa8457f82107df480e04397aa1f636f55429cb.zip
verschiedene Korrekturen
Diffstat (limited to 'gearman/controllerWorker/ControllerWorker/BootWorker.java')
-rw-r--r--gearman/controllerWorker/ControllerWorker/BootWorker.java6
1 files changed, 4 insertions, 2 deletions
diff --git a/gearman/controllerWorker/ControllerWorker/BootWorker.java b/gearman/controllerWorker/ControllerWorker/BootWorker.java
index 9cf5b2e..84a557a 100644
--- a/gearman/controllerWorker/ControllerWorker/BootWorker.java
+++ b/gearman/controllerWorker/ControllerWorker/BootWorker.java
@@ -23,7 +23,9 @@ public class BootWorker extends AbstractGearmanFunction {
String data = ByteUtils.fromUTF8Bytes((byte[]) this.data);
Vector<HashMap<String, String>> clients = new Vector<HashMap<String, String>>();
JSONObject jsonObject = (JSONObject) JSONValue.parse(data);
- String event = jsonObject.get("event").toString();
+ String event = jsonObject.get("eventName").toString();
+ int updateRate = Integer.parseInt(jsonObject.get("updateRate")
+ .toString());
JSONArray jsonArray = (JSONArray) jsonObject.get("clients");
for (Object clientObj : jsonArray) {
@@ -35,7 +37,7 @@ public class BootWorker extends AbstractGearmanFunction {
clients.add(clientMap);
}
- Boot boot = new Boot("127.0.0.1", 4730, clients);
+ Boot boot = new Boot("127.0.0.1", 4730, clients, updateRate);
StatusWorker.BOOTTHREADS.put(event, boot);
boot.start();
System.out.println("Booting started");