From 691f86983b22a8a0f27c7d85818804c1c9932152 Mon Sep 17 00:00:00 2001 From: Amnon Heiman Date: Sun, 31 Jan 2016 13:48:55 +0200 Subject: [PATCH] StorageService: getTokens should return the tokens of the current node StorageService.getTokens should return only the tokens of the current node, not all the tokens. Signed-off-by: Amnon Heiman Message-Id: <1454240935-21903-1-git-send-email-amnon@scylladb.com> --- src/main/java/org/apache/cassandra/service/StorageService.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/org/apache/cassandra/service/StorageService.java b/src/main/java/org/apache/cassandra/service/StorageService.java index 76ad4a0..4e66b29 100644 --- a/src/main/java/org/apache/cassandra/service/StorageService.java +++ b/src/main/java/org/apache/cassandra/service/StorageService.java @@ -45,6 +45,7 @@ import org.apache.cassandra.repair.RepairParallelism; import org.apache.cassandra.streaming.StreamManager; import com.scylladb.jmx.api.APIClient; +import com.scylladb.jmx.api.APIConfig; import com.scylladb.jmx.utils.FileUtils; import com.google.common.base.Joiner; @@ -155,7 +156,7 @@ public class StorageService extends NotificationBroadcasterSupport */ public List getTokens() { log(" getTokens()"); - return c.getListStrValue("/storage_service/tokens/"); + return c.getListStrValue("/storage_service/tokens/" + APIConfig.getAddress()); } /**