Skip to content

Commit

Permalink
Changing unrefernced file cleanup stats based MergeStats metrics vers…
Browse files Browse the repository at this point in the history
…ion to 2.11 (#10336)

Signed-off-by: Rishav Sagar <[email protected]>
Co-authored-by: Rishav Sagar <[email protected]>
  • Loading branch information
RS146BIJAY and Rishav Sagar authored Oct 3, 2023
1 parent bddf0d3 commit d5a95b8
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ public MergeStats(StreamInput in) throws IOException {
totalStoppedTimeInMillis = in.readVLong();
totalThrottledTimeInMillis = in.readVLong();
totalBytesPerSecAutoThrottle = in.readVLong();
if (in.getVersion().onOrAfter(Version.V_3_0_0)) {
if (in.getVersion().onOrAfter(Version.V_2_11_0)) {
unreferencedFileCleanUpsPerformed = in.readOptionalVLong();
}
}
Expand Down Expand Up @@ -297,7 +297,7 @@ public void writeTo(StreamOutput out) throws IOException {
out.writeVLong(totalStoppedTimeInMillis);
out.writeVLong(totalThrottledTimeInMillis);
out.writeVLong(totalBytesPerSecAutoThrottle);
if (out.getVersion().onOrAfter(Version.V_3_0_0)) {
if (out.getVersion().onOrAfter(Version.V_2_11_0)) {
out.writeOptionalVLong(unreferencedFileCleanUpsPerformed);
}
}
Expand Down

0 comments on commit d5a95b8

Please sign in to comment.