public DiskMetrics getDiskMetrics() {
    return diskMetrics;
  }
Gets the {@link FileSpan} for a message that is written starting at {@code endOffsetOfPrevMessage} and is of size
{@code size}. This function is safe to use only immediately after a write to the log to get the {@link FileSpan}
for an index entry.
@param endOffsetOfPrevMessage the end offset of the message that is before this one.
@param size the size of the write.
@return the {@link FileSpan} for a message that is written starting at {@code endOffsetOfPrevMessage} and is of
size {@code size}.
ambry-store/src/main/java/com/github/ambry/store/Log.java