public Set<Long> getMemTableIds(long fileVersionId) {
    if (fileVersionId >= currentWALFileVersion) {
      return null;
    }
    return memTableIdsOfWal.computeIfAbsent(
        fileVersionId,
        id -> {
          try {
            File file = WALFileUtils.getWALFile(new File(logDirectory), id);
            return WALMetaData.readFromWALFile(
                    file, FileChannel.open(file.toPath(), StandardOpenOption.READ))
                .getMemTablesId();
          } catch (BrokenWALFileException e) {
            logger.warn(
                "Fail to read memTable ids from the wal file {} of wal node {}: {}",
                id,
                identifier,
                e.getMessage());
          } catch (IOException e) {
            logger.warn(
                "Fail to read memTable ids from the wal file {} of wal node {}.",
                id,
                identifier,
                e);
          }
          return Collections.emptySet();
        });
  }
This task syncs syncingBuffer to disk. The precondition is that syncingBuffer cannot be null.
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/storageengine/dataregion/wal/buffer/WALBuffer.java