@@ -59,7 +59,7 @@ public ClusterStatsRequest(StreamInput in) throws IOException {
5959 if (in .getVersion ().onOrAfter (Version .V_2_16_0 )) {
6060 useAggregatedNodeLevelResponses = in .readOptionalBoolean ();
6161 }
62- if (in .getVersion ().onOrAfter (Version .V_3_0_0 )) {
62+ if (in .getVersion ().onOrAfter (Version .V_2_18_0 )) {
6363 computeAllMetrics = in .readOptionalBoolean ();
6464 final long longMetricsFlags = in .readLong ();
6565 for (Metric metric : Metric .values ()) {
@@ -135,7 +135,7 @@ public void writeTo(StreamOutput out) throws IOException {
135135 if (out .getVersion ().onOrAfter (Version .V_2_16_0 )) {
136136 out .writeOptionalBoolean (useAggregatedNodeLevelResponses );
137137 }
138- if (out .getVersion ().onOrAfter (Version .V_3_0_0 )) {
138+ if (out .getVersion ().onOrAfter (Version .V_2_18_0 )) {
139139 out .writeOptionalBoolean (computeAllMetrics );
140140 long longMetricFlags = 0 ;
141141 for (Metric metric : requestedMetrics ) {
@@ -154,7 +154,7 @@ public void writeTo(StreamOutput out) throws IOException {
154154 * An enumeration of the "core" sections of metrics that may be requested
155155 * from the cluster stats endpoint.
156156 */
157- @ PublicApi (since = "3.0 .0" )
157+ @ PublicApi (since = "2.18 .0" )
158158 public enum Metric {
159159 OS ("os" , 0 ),
160160 JVM ("jvm" , 1 ),
@@ -192,7 +192,7 @@ public int getIndex() {
192192 *
193193 * When no value is provided for param index_metric, default filter is set to _all.
194194 */
195- @ PublicApi (since = "3.0 .0" )
195+ @ PublicApi (since = "2.18 .0" )
196196 public enum IndexMetric {
197197 // Metrics computed from ShardStats
198198 SHARDS ("shards" , 0 ),
0 commit comments