public boolean reachesFileEndBy(final int waitToWroteSize) {
        return getWrotePosition() + waitToWroteSize > getFileSize();
    }
Update  flush / wrote position to pos
@param pos target pos
jraft-extension/java-log-storage-impl/src/main/java/com/alipay/sofa/jraft/storage/file/AbstractFile.java