From ea3fa768f95a0645684e153d41563bcd9117fd1b Mon Sep 17 00:00:00 2001 From: Martijn van Groningen Date: Wed, 30 Aug 2017 19:37:21 +0200 Subject: [PATCH] Changed version from 7.0.0-alpha1 to 6.1.0 in the nested sorting serialization check. --- .../java/org/elasticsearch/search/sort/FieldSortBuilder.java | 4 ++-- .../org/elasticsearch/search/sort/GeoDistanceSortBuilder.java | 4 ++-- .../java/org/elasticsearch/search/sort/ScriptSortBuilder.java | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/core/src/main/java/org/elasticsearch/search/sort/FieldSortBuilder.java b/core/src/main/java/org/elasticsearch/search/sort/FieldSortBuilder.java index 22e656ba387..6b2c82a7b67 100644 --- a/core/src/main/java/org/elasticsearch/search/sort/FieldSortBuilder.java +++ b/core/src/main/java/org/elasticsearch/search/sort/FieldSortBuilder.java @@ -118,7 +118,7 @@ public class FieldSortBuilder extends SortBuilder { order = in.readOptionalWriteable(SortOrder::readFromStream); sortMode = in.readOptionalWriteable(SortMode::readFromStream); unmappedType = in.readOptionalString(); - if (in.getVersion().onOrAfter(Version.V_7_0_0_alpha1)) { + if (in.getVersion().onOrAfter(Version.V_6_1_0)) { nestedSort = in.readOptionalWriteable(NestedSortBuilder::new); } } @@ -132,7 +132,7 @@ public class FieldSortBuilder extends SortBuilder { out.writeOptionalWriteable(order); out.writeOptionalWriteable(sortMode); out.writeOptionalString(unmappedType); - if (out.getVersion().onOrAfter(Version.V_7_0_0_alpha1)) { + if (out.getVersion().onOrAfter(Version.V_6_1_0)) { out.writeOptionalWriteable(nestedSort); } } diff --git a/core/src/main/java/org/elasticsearch/search/sort/GeoDistanceSortBuilder.java b/core/src/main/java/org/elasticsearch/search/sort/GeoDistanceSortBuilder.java index 686b241489b..f639f760223 100644 --- a/core/src/main/java/org/elasticsearch/search/sort/GeoDistanceSortBuilder.java +++ b/core/src/main/java/org/elasticsearch/search/sort/GeoDistanceSortBuilder.java @@ -166,7 +166,7 @@ public class GeoDistanceSortBuilder extends SortBuilder sortMode = in.readOptionalWriteable(SortMode::readFromStream); nestedFilter = in.readOptionalNamedWriteable(QueryBuilder.class); nestedPath = in.readOptionalString(); - if (in.getVersion().onOrAfter(Version.V_7_0_0_alpha1)) { + if (in.getVersion().onOrAfter(Version.V_6_1_0)) { nestedSort = in.readOptionalWriteable(NestedSortBuilder::new); } validation = GeoValidationMethod.readFromStream(in); @@ -182,7 +182,7 @@ public class GeoDistanceSortBuilder extends SortBuilder out.writeOptionalWriteable(sortMode); out.writeOptionalNamedWriteable(nestedFilter); out.writeOptionalString(nestedPath); - if (out.getVersion().onOrAfter(Version.V_7_0_0_alpha1)) { + if (out.getVersion().onOrAfter(Version.V_6_1_0)) { out.writeOptionalWriteable(nestedSort); } validation.writeTo(out); diff --git a/core/src/main/java/org/elasticsearch/search/sort/ScriptSortBuilder.java b/core/src/main/java/org/elasticsearch/search/sort/ScriptSortBuilder.java index 866ace6313e..e9f28f4617e 100644 --- a/core/src/main/java/org/elasticsearch/search/sort/ScriptSortBuilder.java +++ b/core/src/main/java/org/elasticsearch/search/sort/ScriptSortBuilder.java @@ -120,7 +120,7 @@ public class ScriptSortBuilder extends SortBuilder { sortMode = in.readOptionalWriteable(SortMode::readFromStream); nestedPath = in.readOptionalString(); nestedFilter = in.readOptionalNamedWriteable(QueryBuilder.class); - if (in.getVersion().onOrAfter(Version.V_7_0_0_alpha1)) { + if (in.getVersion().onOrAfter(Version.V_6_1_0)) { nestedSort = in.readOptionalWriteable(NestedSortBuilder::new); } } @@ -133,7 +133,7 @@ public class ScriptSortBuilder extends SortBuilder { out.writeOptionalWriteable(sortMode); out.writeOptionalString(nestedPath); out.writeOptionalNamedWriteable(nestedFilter); - if (out.getVersion().onOrAfter(Version.V_7_0_0_alpha1)) { + if (out.getVersion().onOrAfter(Version.V_6_1_0)) { out.writeOptionalWriteable(nestedSort); } }