From a0c21f853fa4979d3eea2a02efb3104dddf74362 Mon Sep 17 00:00:00 2001 From: Simon Cooper Date: Wed, 14 Feb 2024 09:24:25 +0000 Subject: [PATCH] Map old release version id directly to their version, don't specify a range (#105335) --- .../src/main/java/org/elasticsearch/ReleaseVersions.java | 7 ++++--- .../test/java/org/elasticsearch/ReleaseVersionsTests.java | 2 +- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/server/src/main/java/org/elasticsearch/ReleaseVersions.java b/server/src/main/java/org/elasticsearch/ReleaseVersions.java index 6e7cf6c428cd6..7b5c8d1d42382 100644 --- a/server/src/main/java/org/elasticsearch/ReleaseVersions.java +++ b/server/src/main/java/org/elasticsearch/ReleaseVersions.java @@ -105,14 +105,15 @@ private static IntFunction lookupFunction(NavigableMap versions = ReleaseVersions.generateVersionsLookup(ReleaseVersionsTests.class); assertThat(versions.apply(17), equalTo("8.1.2-8.2.0")); - assertThat(versions.apply(9), equalTo("0.0.0-8.0.0")); + assertThat(versions.apply(9), equalTo("0.0.0")); assertThat(versions.apply(24), equalTo("8.2.2-snapshot[24]")); } }