diff --git a/java/runtime/src/main/java/org/ray/runtime/gcs/GcsClient.java b/java/runtime/src/main/java/org/ray/runtime/gcs/GcsClient.java index 1b46a3a2b..ca10f24d7 100644 --- a/java/runtime/src/main/java/org/ray/runtime/gcs/GcsClient.java +++ b/java/runtime/src/main/java/org/ray/runtime/gcs/GcsClient.java @@ -48,7 +48,7 @@ public class GcsClient { List shardAddresses = primary.lrange("RedisShards".getBytes(), 0, -1); Preconditions.checkState(shardAddresses.size() == numShards); shards = shardAddresses.stream().map((byte[] address) -> { - return new RedisClient(new String(address)); + return new RedisClient(new String(address), redisPassword); }).collect(Collectors.toList()); } diff --git a/java/runtime/src/main/resources/ray.default.conf b/java/runtime/src/main/resources/ray.default.conf index 208a07b5a..0dbc2c59c 100644 --- a/java/runtime/src/main/resources/ray.default.conf +++ b/java/runtime/src/main/resources/ray.default.conf @@ -59,10 +59,11 @@ ray { address: "" // If `redis.server` isn't provided, which port we should use to start redis server. head-port: 6379 + // Below passwords should be consistent with the one defined in python/ray/ray_constants.py. // The password used to start the redis server on the head node. - head-password: "" + head-password: "5241590000000000" // The password used to connect to the redis server. - password:"" + password: "5241590000000000" // If `redis.server` isn't provided, how many Redis shards we should start in addition to the // primary Redis shard. The ports of these shards will be `head-port + 1`, `head-port + 2`, etc. shard-number: 1