Skip to content

Commit

Permalink
test: adding optimizedFlags on main - 2
Browse files Browse the repository at this point in the history
  • Loading branch information
Pranshu-S committed Jul 11, 2024
1 parent 7b83a9e commit 81547bb
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public class CommonStatsFlags implements Writeable, Cloneable {
private EnumSet<CacheType> includeCaches = EnumSet.noneOf(CacheType.class);
private String[] levels = new String[0];

private boolean optimizeNodeIndicesStatsOnLevel = false;
private Boolean optimizeNodeIndicesStatsOnLevel = false;

/**
* @param flags flags to set. If no flags are supplied, default flags will be set.
Expand Down Expand Up @@ -103,7 +103,7 @@ public CommonStatsFlags(StreamInput in) throws IOException {
levels = in.readStringArray();
}
if (in.getVersion().onOrAfter(Version.V_2_16_0)) {
optimizeNodeIndicesStatsOnLevel = in.readBoolean();
optimizeNodeIndicesStatsOnLevel = in.readOptionalBoolean();
}
}

Expand All @@ -130,7 +130,7 @@ public void writeTo(StreamOutput out) throws IOException {
out.writeStringArrayNullable(levels);
}
if (out.getVersion().onOrAfter(Version.V_2_16_0)) {
out.writeBoolean(optimizeNodeIndicesStatsOnLevel);
out.writeOptionalBoolean(optimizeNodeIndicesStatsOnLevel);
}
}

Expand Down

0 comments on commit 81547bb

Please sign in to comment.