summaryrefslogtreecommitdiffstats
path: root/vespaclient-java
diff options
context:
space:
mode:
authorArne Juul <arnej@yahoo-inc.com>2019-03-15 13:47:06 +0000
committerArne Juul <arnej@yahoo-inc.com>2019-03-15 13:47:06 +0000
commit24241ae843cdced8403b9aa86e5895d0460dc410 (patch)
treef077aee1ed1e3140fe7f38be9414b4f6ebbea0d0 /vespaclient-java
parentaef75eae6244583e7ad429049ad4efe1ec46e70b (diff)
remove "headersonly" command line option completely
Diffstat (limited to 'vespaclient-java')
-rw-r--r--vespaclient-java/src/main/java/com/yahoo/vespaget/CommandLineOptions.java10
-rw-r--r--vespaclient-java/src/main/java/com/yahoo/vespavisit/VdsVisit.java2
-rw-r--r--vespaclient-java/src/test/java/com/yahoo/vespaget/CommandLineOptionsTest.java7
3 files changed, 0 insertions, 19 deletions
diff --git a/vespaclient-java/src/main/java/com/yahoo/vespaget/CommandLineOptions.java b/vespaclient-java/src/main/java/com/yahoo/vespaget/CommandLineOptions.java
index 5b006b9d1eb..0bfdcbe75ff 100644
--- a/vespaclient-java/src/main/java/com/yahoo/vespaget/CommandLineOptions.java
+++ b/vespaclient-java/src/main/java/com/yahoo/vespaget/CommandLineOptions.java
@@ -25,7 +25,6 @@ public class CommandLineOptions {
public static final String HELP_OPTION = "help";
public static final String PRINTIDS_OPTION = "printids";
- public static final String HEADERSONLY_OPTION = "headersonly";
public static final String FIELDSET_OPTION = "fieldset";
public static final String CLUSTER_OPTION = "cluster";
public static final String ROUTE_OPTION = "route";
@@ -66,11 +65,6 @@ public class CommandLineOptions {
.longOpt(PRINTIDS_OPTION)
.build());
- options.addOption(Option.builder("e")
- .hasArg(false)
- .desc("Retrieve header fields only. [Removed in Vespa 7].")
- .longOpt(HEADERSONLY_OPTION).build());
-
options.addOption(Option.builder("f")
.hasArg(true)
.desc("Retrieve the specified fields only (see https://docs.vespa.ai/documentation/documents.html#fieldsets) (default '[all]')")
@@ -160,7 +154,6 @@ public class CommandLineOptions {
CommandLine cl = clp.parse(options, args);
boolean printIdsOnly = cl.hasOption(PRINTIDS_OPTION);
- boolean headersOnly = cl.hasOption(HEADERSONLY_OPTION);
String fieldSet = cl.getOptionValue(FIELDSET_OPTION, "");
String cluster = cl.getOptionValue(CLUSTER_OPTION, "");
String route = cl.getOptionValue(ROUTE_OPTION, "");
@@ -180,9 +173,6 @@ public class CommandLineOptions {
throw new IllegalArgumentException("Cannot combine both xml and json output");
}
- if (headersOnly) {
- throw new IllegalArgumentException("Headers only option has been removed.");
- }
if (printIdsOnly && !fieldSet.isEmpty()) {
throw new IllegalArgumentException("Field set option can not be used in combination with print ids option.");
}
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 7b938e8ec3f..a92caa4466d 100644
--- a/vespaclient-java/src/main/java/com/yahoo/vespavisit/VdsVisit.java
+++ b/vespaclient-java/src/main/java/com/yahoo/vespavisit/VdsVisit.java
@@ -189,8 +189,6 @@ public class VdsVisit {
.desc("Only visit up to the given timestamp (microseconds).")
.type(Number.class).build());
- options.addOption("e", "headersonly", false, "Only visit headers of documents.[Removed in Vespa 7]");
-
options.addOption(Option.builder("l")
.longOpt("fieldset")
.hasArg(true)
diff --git a/vespaclient-java/src/test/java/com/yahoo/vespaget/CommandLineOptionsTest.java b/vespaclient-java/src/test/java/com/yahoo/vespaget/CommandLineOptionsTest.java
index a9d8b85c480..50b499b8df2 100644
--- a/vespaclient-java/src/test/java/com/yahoo/vespaget/CommandLineOptionsTest.java
+++ b/vespaclient-java/src/test/java/com/yahoo/vespaget/CommandLineOptionsTest.java
@@ -142,13 +142,6 @@ public class CommandLineOptionsTest {
}
@Test
- public void testHeadersOnly() {
- exception.expect(IllegalArgumentException.class);
- exception.expectMessage("Headers only option has been removed.");
- getParsedOptions("--headersonly");
- }
-
- @Test
public void testCluster() {
ClientParameters params = getParsedOptions("--cluster", "dummycluster");
assertEquals("dummycluster", params.cluster);