[Java] Java worker cluster support (#2359)

This commit is contained in:
Zhijun Fu
2018-07-10 01:20:41 +08:00
committed by Robert Nishihara
parent 4ef9d15315
commit fa33ea5283
16 changed files with 661 additions and 19 deletions
@@ -33,6 +33,12 @@ public class HelloWorld implements Serializable {
public static void main(String[] args) throws Exception {
try {
Ray.init();
RayLog.rapp.info("HelloWorld.main() has " + args.length + " args");
for (String arg: args) {
RayLog.rapp.info("arg: " + arg);
}
String helloWorld = HelloWorld.sayHelloWorld();
RayLog.rapp.info(helloWorld);
assert helloWorld.equals("hello,world!");
@@ -41,8 +47,6 @@ public class HelloWorld implements Serializable {
} finally {
RayRuntime.getInstance().cleanUp();
}
}
public static String sayHelloWorld() {