diff --git a/server/src/main/java/org/opensearch/search/profile/query/CollectorResult.java b/server/src/main/java/org/opensearch/search/profile/query/CollectorResult.java index a624cbc0bb7d6..73dd2214959ad 100644 --- a/server/src/main/java/org/opensearch/search/profile/query/CollectorResult.java +++ b/server/src/main/java/org/opensearch/search/profile/query/CollectorResult.java @@ -164,7 +164,7 @@ public CollectorResult(StreamInput in) throws IOException { CollectorResult child = new CollectorResult(in); this.children.add(child); } - if (in.getVersion().onOrAfter(Version.V_3_0_0)) { + if (in.getVersion().onOrAfter(Version.V_2_9_0)) { this.reduceTime = in.readLong(); this.maxSliceTime = in.readLong(); this.minSliceTime = in.readLong(); @@ -188,7 +188,7 @@ public void writeTo(StreamOutput out) throws IOException { for (CollectorResult child : children) { child.writeTo(out); } - if (out.getVersion().onOrAfter(Version.V_3_0_0)) { + if (out.getVersion().onOrAfter(Version.V_2_9_0)) { out.writeLong(reduceTime); out.writeLong(maxSliceTime); out.writeLong(minSliceTime);