@Override
  public IMemMNode setToInternal(final IDeviceMNode<IMemMNode> entityMNode) {
    int rawSize = entityMNode.estimateSize();
    if (MNodeUtils.setToInternal(entityMNode)) {
      regionStatistics.deleteDevice();
      releaseMemory(rawSize - entityMNode.estimateSize());
    }

    return entityMNode.getAsMNode();
  }
This is a memory-based implementation of IMTreeStore. All MNodes are stored in memory.
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/schemaengine/schemaregion/mtree/impl/mem/MemMTreeStore.java