public void increaseFileReaderReference(TsFileResource tsFile, boolean isClosed) {
    tsFile.readLock();
    synchronized (this) {
      if (!isClosed) {
        unclosedReferenceMap
            .computeIfAbsent(tsFile.getTsFilePath(), k -> new AtomicInteger())
            .getAndIncrement();
      } else {
        closedReferenceMap
            .computeIfAbsent(tsFile.getTsFilePath(), k -> new AtomicInteger())
            .getAndIncrement();
      }
    }
  }
Increase the reference count of the reader specified by filePath. Only when the reference count
of a reader equals zero, the reader can be closed and removed.
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/storageengine/dataregion/read/control/FileReaderManager.java