public void registerToTsFile(
      String tableName, Function<String, TableSchema> tableSchemaFunction) {
    getWriter().getSchema().getTableSchemaMap().computeIfAbsent(tableName, tableSchemaFunction);
  }
Return Long.MAX_VALUE if workMemTable is null
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/storageengine/dataregion/memtable/TsFileProcessor.java