From 3d67915ed5869148725f5b99412d525da305f208 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Christoph=20B=C3=BCscher?= Date: Wed, 20 Sep 2017 16:14:11 +0200 Subject: [PATCH] #26720: Set the correct bwc version after backport to 6.0 --- .../elasticsearch/index/query/MatchQueryBuilder.java | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/core/src/main/java/org/elasticsearch/index/query/MatchQueryBuilder.java b/core/src/main/java/org/elasticsearch/index/query/MatchQueryBuilder.java index 1b126edbd12..cc19603ea64 100644 --- a/core/src/main/java/org/elasticsearch/index/query/MatchQueryBuilder.java +++ b/core/src/main/java/org/elasticsearch/index/query/MatchQueryBuilder.java @@ -110,13 +110,11 @@ public class MatchQueryBuilder extends AbstractQueryBuilder { super(in); fieldName = in.readString(); value = in.readGenericValue(); - // TODO lower this version once this has been backported to 6.0.0 - if (in.getVersion().before(Version.V_7_0_0_alpha1)) { + if (in.getVersion().before(Version.V_6_0_0_rc1)) { MatchQuery.Type.readFromStream(in); // deprecated type } operator = Operator.readFromStream(in); - // TODO lower this version once this has been backported to 6.0.0 - if (in.getVersion().before(Version.V_7_0_0_alpha1)) { + if (in.getVersion().before(Version.V_6_0_0_rc1)) { in.readVInt(); // deprecated slop } prefixLength = in.readVInt(); @@ -139,13 +137,11 @@ public class MatchQueryBuilder extends AbstractQueryBuilder { protected void doWriteTo(StreamOutput out) throws IOException { out.writeString(fieldName); out.writeGenericValue(value); - // TODO lower this version once this has been backported to 6.0.0 - if (out.getVersion().before(Version.V_7_0_0_alpha1)) { + if (out.getVersion().before(Version.V_6_0_0_rc1)) { MatchQuery.Type.BOOLEAN.writeTo(out); // deprecated type } operator.writeTo(out); - // TODO lower this version once this has been backported to 6.0.0 - if (out.getVersion().before(Version.V_7_0_0_alpha1)) { + if (out.getVersion().before(Version.V_6_0_0_rc1)) { out.writeVInt(MatchQuery.DEFAULT_PHRASE_SLOP); // deprecated slop } out.writeVInt(prefixLength);