From d8b50a5018b8375bb4ae5a98c796a67d74f7c3be Mon Sep 17 00:00:00 2001 From: Kai Yang Date: Thu, 11 Jul 2019 16:05:12 +0800 Subject: [PATCH] Fix GcsClient resource map (#5171) --- .../runtime/src/main/java/org/ray/runtime/gcs/GcsClient.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) 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 97f98eaab..6ce8ad20e 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 @@ -1,7 +1,6 @@ package org.ray.runtime.gcs; import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; import com.google.protobuf.InvalidProtocolBufferException; import java.util.ArrayList; import java.util.HashMap; @@ -77,12 +76,12 @@ public class GcsClient { if (data.getIsInsertion()) { //Code path of node insertion. NodeInfo nodeInfo = new NodeInfo( - clientId, data.getNodeManagerAddress(), true, ImmutableMap.of()); + clientId, data.getNodeManagerAddress(), true, new HashMap<>()); clients.put(clientId, nodeInfo); } else { // Code path of node deletion. NodeInfo nodeInfo = new NodeInfo(clientId, clients.get(clientId).nodeAddress, - false, ImmutableMap.of()); + false, new HashMap<>()); clients.put(clientId, nodeInfo); } }