@TestOnly
  public long getTargetSegmentAddressOnTest(long curSegAddr, String recKey)
      throws IOException, MetadataException {
    return getTargetSegmentAddress(curSegAddr, recKey, new SchemaPageContext());
  }
This method {@linkplain #reEstimateSegSize} is called when {@linkplain
SchemaPageOverflowException} occurs. It is designed to accelerate when there is lots of new
children nodes, avoiding segments extend several times.

<p>Notice that SegmentOverflowException inside a page with sufficient space will not reach
here. Supposed to merge with SchemaFile#reEstimateSegSize.

@param expSize expected size calculated from next new record
@param batchSize size of children within one #writeNewChildren(ICachedMNode)
@return estimated size
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/schemaengine/schemaregion/mtree/impl/pbtree/schemafile/pagemgr/PageManager.java