@Override
  public void clear() {
    nodesLock.lock();
    try {
      nodeIdCounter = -1;
      uniqueId2Nodes.clear();
      for (WALNode walNode : walNodes) {
        walNode.close();
      }
      walNodes.clear();
    } finally {
      nodesLock.unlock();
    }
  }
This strategy creates wal nodes according to the number of memTables. Each wal node manages fixed
number of memTables.
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/storageengine/dataregion/wal/allocation/ElasticStrategy.java