Github user zzcclp commented on a diff in the pull request:
@@ -107,4 +114,36 @@ public static int getLockProperty(String property, int
+ * Currently the segment lock files are not deleted immediately when
+ * so it needs to delete expired lock files before delete loads.
+ public static void deleteExpiredSegmentLockFiles(CarbonTable
+ LoadMetadataDetails details =
--- End diff --
I think it is better to use this method to check the status and last
modified time of the segment at the same time. As the size of the tablestatus
file is getting larger, it is a problem, there are many places will scan this
file, not just here, we need to solve this problem. I have raise a
to discuss this on mailling list.