private boolean isMetadata(final byte[] data) {
        for (int offset = 0; offset < SegmentFile.RECORD_MAGIC_BYTES_SIZE; offset++) {
            if (data[offset] != SegmentFile.RECORD_MAGIC_BYTES[offset]) {
                return false;
            }
        }
        return true;
    }
It's wrote position is from start(HEADER_SIZE) but it's not the last file, SHOULD not happen.
jraft-core/src/main/java/com/alipay/sofa/jraft/storage/log/RocksDBSegmentLogStorage.java