@Override
  public long getTemplateSeriesNumber() {
    return templateUsage.entrySet().stream()
        .mapToLong(
            i ->
                (long) clusterTemplateManager.getTemplate(i.getKey()).getMeasurementNumber()
                    * i.getValue())
        .sum();
  }
This class is used to record the global statistics of SchemaEngine in Memory mode.
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/schemaengine/rescon/MemSchemaEngineStatistics.java