diff options
author | Jon Marius Venstad <venstad@gmail.com> | 2021-01-04 16:43:06 +0100 |
---|---|---|
committer | Jon Marius Venstad <venstad@gmail.com> | 2021-01-04 16:43:06 +0100 |
commit | b1e15a0e12bc6fb258b65cdd6e6fcfb925e8f3c1 (patch) | |
tree | 2676f0ddbf2df00c17cdd362559d2c4890a3d0a6 /vespaclient-java/src | |
parent | 6eede0d2c93cd086a980d2bed5c5cc5d1eca9712 (diff) |
Use clustername-direct routes for visitors
Diffstat (limited to 'vespaclient-java/src')
4 files changed, 5 insertions, 5 deletions
diff --git a/vespaclient-java/src/main/java/com/yahoo/vespaget/DocumentRetriever.java b/vespaclient-java/src/main/java/com/yahoo/vespaget/DocumentRetriever.java index 21424ac335c..ebed1685a5f 100644 --- a/vespaclient-java/src/main/java/com/yahoo/vespaget/DocumentRetriever.java +++ b/vespaclient-java/src/main/java/com/yahoo/vespaget/DocumentRetriever.java @@ -116,7 +116,7 @@ public class DocumentRetriever { "The Vespa cluster contains the content clusters %s, not %s. Please select a valid vespa cluster.", names, clusterName)); } - return clusterDef.getName(); + return clusterDef.getRoute(); } private LoadType resolveLoadType(String loadTypeName) throws DocumentRetrieverException { diff --git a/vespaclient-java/src/main/java/com/yahoo/vespavisit/VdsVisit.java b/vespaclient-java/src/main/java/com/yahoo/vespavisit/VdsVisit.java index 386679abc94..b1f91e44e5c 100644 --- a/vespaclient-java/src/main/java/com/yahoo/vespavisit/VdsVisit.java +++ b/vespaclient-java/src/main/java/com/yahoo/vespavisit/VdsVisit.java @@ -600,7 +600,7 @@ public class VdsVisit { names + ". Please use the -c option to select one of them as a target for visiting."); } - return found.getName(); + return found.getRoute(); } protected static void verbosePrintParameters(VdsVisitParameters vdsParams, PrintStream out) { diff --git a/vespaclient-java/src/test/java/com/yahoo/vespaget/DocumentRetrieverTest.java b/vespaclient-java/src/test/java/com/yahoo/vespaget/DocumentRetrieverTest.java index ea7781e657c..d6bda4b8bc1 100644 --- a/vespaclient-java/src/test/java/com/yahoo/vespaget/DocumentRetrieverTest.java +++ b/vespaclient-java/src/test/java/com/yahoo/vespaget/DocumentRetrieverTest.java @@ -235,7 +235,7 @@ public class DocumentRetrieverTest { @Test public void testClusterLookup() throws DocumentRetrieverException { final String cluster = "storage", - expectedRoute = "storage"; + expectedRoute = "storage-direct"; ClientParameters params = createParameters() .setCluster(cluster) diff --git a/vespaclient-java/src/test/java/com/yahoo/vespavisit/VdsVisitTestCase.java b/vespaclient-java/src/test/java/com/yahoo/vespavisit/VdsVisitTestCase.java index b7412fe9905..7828fbb249d 100644 --- a/vespaclient-java/src/test/java/com/yahoo/vespavisit/VdsVisitTestCase.java +++ b/vespaclient-java/src/test/java/com/yahoo/vespavisit/VdsVisitTestCase.java @@ -232,7 +232,7 @@ public class VdsVisitTestCase { ClusterList clusterList = new ClusterList(clusterDefs); String route = VdsVisit.resolveClusterRoute(clusterList, null); - assertEquals("storage", route); + assertEquals("storage-direct", route); } @Test @@ -270,7 +270,7 @@ public class VdsVisitTestCase { ClusterList clusterList = new ClusterList(clusterDefs); String route = VdsVisit.resolveClusterRoute(clusterList, "storage2"); - assertEquals("storage2", route); + assertEquals("storage2-direct", route); } @Test |