jt2594838 commented on a change in pull request #429: [IOTDB-205]Support 
storage-group-level data ttl
URL: https://github.com/apache/incubator-iotdb/pull/429#discussion_r339513700
 
 

 ##########
 File path: 
server/src/main/java/org/apache/iotdb/db/engine/storagegroup/StorageGroupProcessor.java
 ##########
 @@ -582,6 +612,65 @@ public void syncDeleteDataFiles() {
     }
   }
 
+  /**
+   * Iterate each TsFile and try to lock and remove those out of TTL.
+   */
+  public synchronized void checkFilesTTL() {
+    if (dataTTL == Long.MAX_VALUE) {
+      logger.debug("{}: TTL not set, ignore the check", storageGroupName);
+      return;
+    }
+    long timeBound = System.currentTimeMillis() - dataTTL;
 
 Review comment:
   Changed.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to