Browse Source

Reenable BWC tests after backport of #71725 (#71732)

This commit reenables BWC tests (disabled in #71728) and adjusts some versions.
Tanguy Leroux 4 năm trước cách đây
mục cha
commit
d1c3b71384

+ 2 - 2
build.gradle

@@ -190,9 +190,9 @@ tasks.register("verifyVersions") {
  * after the backport of the backcompat code is complete.
  */
 
-boolean bwc_tests_enabled = false
+boolean bwc_tests_enabled = true
 // place a PR link here when committing bwc changes:
-String bwc_tests_disabled_issue = "https://github.com/elastic/elasticsearch/pull/71725"
+String bwc_tests_disabled_issue = ""
 /*
  * FIPS 140-2 behavior was fixed in 7.11.0. Before that there is no way to run elasticsearch in a
  * JVM that is properly configured to be in fips mode with BCFIPS. For now we need to disable

+ 2 - 2
rest-api-spec/src/yamlRestTest/resources/rest-api-spec/test/indices.stats/30_segments.yml

@@ -67,8 +67,8 @@ setup:
 "Indices Stats API with extended files stats":
 
   - skip:
-      version: " - 7.99.99"
-      reason: segment files stats extended in 8.0.0
+      version: " - 7.12.99"
+      reason: segment files stats extended in 7.13.0
 
   - do:
       index:

+ 2 - 2
server/src/main/java/org/elasticsearch/index/engine/SegmentsStats.java

@@ -356,7 +356,7 @@ public class SegmentsStats implements Writeable, ToXContentFragment {
         private final long max;
 
         FileStats(StreamInput in) throws IOException {
-            if (in.getVersion().onOrAfter(Version.V_8_0_0)) {
+            if (in.getVersion().onOrAfter(Version.V_7_13_0)) {
                 this.ext = in.readString();
                 this.total = in.readVLong();
                 this.count = in.readVLong();
@@ -401,7 +401,7 @@ public class SegmentsStats implements Writeable, ToXContentFragment {
 
         @Override
         public void writeTo(StreamOutput out) throws IOException {
-            if (out.getVersion().onOrAfter(Version.V_8_0_0)) {
+            if (out.getVersion().onOrAfter(Version.V_7_13_0)) {
                 out.writeString(ext);
                 out.writeVLong(total);
                 out.writeVLong(count);

+ 2 - 2
x-pack/plugin/searchable-snapshots/qa/rest/src/yamlRestTest/resources/rest-api-spec/test/indices_stats.yml

@@ -1,8 +1,8 @@
 ---
 setup:
   - skip:
-      version: " - 7.99.99"
-      reason: segment files stats enhanced in 8.0.0
+      version: " - 7.12.99"
+      reason: segment files stats enhanced in 7.13.0
 
   - do:
       indices.create: