You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by GitBox <gi...@apache.org> on 2022/03/07 11:24:55 UTC

[GitHub] [iotdb] qiaojialin commented on a change in pull request #5177: [IOTDB-2680]Fix too many open files exception

qiaojialin commented on a change in pull request #5177:
URL: https://github.com/apache/iotdb/pull/5177#discussion_r820613912



##########
File path: server/src/main/java/org/apache/iotdb/db/engine/compaction/cross/rewrite/selector/RewriteCompactionFileSelector.java
##########
@@ -195,7 +198,9 @@ void select(boolean useTightBound) throws IOException {
   }
 
   private boolean updateSelectedFiles(long newCost, TsFileResource unseqFile) {
-    if (totalCost + newCost < memoryBudget) {
+    if (selectedSeqFiles.size() + selectedUnseqFiles.size() + 1 + tmpSelectedSeqFiles.size()
+            < maxCrossCompactionFileNum

Review comment:
       ```suggestion
               <= maxCrossCompactionFileNum
   ```




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org