This is an automated email from the ASF dual-hosted git repository. jackietien pushed a commit to branch new_object_type in repository https://gitbox.apache.org/repos/asf/iotdb.git
commit 9e0d8c36b59af218c1befd2bdaa55dbdf9bdca19 Author: shuwenwei <[email protected]> AuthorDate: Mon Jul 14 15:45:05 2025 +0800 fix ttl deletion --- .../main/java/org/apache/iotdb/db/utils/ObjectTypeUtils.java | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/utils/ObjectTypeUtils.java b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/utils/ObjectTypeUtils.java index ba33a964228..ee2fcb8dc57 100644 --- a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/utils/ObjectTypeUtils.java +++ b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/utils/ObjectTypeUtils.java @@ -68,15 +68,9 @@ public class ObjectTypeUtils { logger.info("Remove object file {}", file.get().getAbsolutePath()); for (int i = 0; i < 2; i++) { try { - if (Files.deleteIfExists(file.get().toPath())) { - return; - } - if (Files.deleteIfExists(tmpFile.toPath())) { - return; - } - if (Files.deleteIfExists(bakFile.toPath())) { - return; - } + Files.deleteIfExists(file.get().toPath()); + Files.deleteIfExists(tmpFile.toPath()); + Files.deleteIfExists(bakFile.toPath()); } catch (IOException e) { logger.error("Failed to remove object file {}", file.get().getAbsolutePath(), e); }
