public void flush() {
        lock.lock();
        try {
            mmap.force();
        } finally {
            lock.unlock();
        }
    }
Flush the data in the index to disk
storage/src/main/java/org/apache/kafka/storage/internals/log/AbstractIndex.java