dawidwys commented on code in PR #18539: URL: https://github.com/apache/flink/pull/18539#discussion_r856213164
########## flink-runtime/src/main/java/org/apache/flink/runtime/checkpoint/Checkpoints.java: ########## @@ -369,4 +373,37 @@ public static CheckpointStorage loadCheckpointStorage( /** This class contains only static utility methods and is not meant to be instantiated. */ private Checkpoints() {} + + private static class ClaimModeCompletedStorageLocation + implements CompletedCheckpointStorageLocation { + + private final CompletedCheckpointStorageLocation wrapped; + + private ClaimModeCompletedStorageLocation(CompletedCheckpointStorageLocation location) { + wrapped = location; + } + + @Override + public String getExternalPointer() { + return wrapped.getExternalPointer(); + } + + @Override + public StreamStateHandle getMetadataHandle() { + return wrapped.getMetadataHandle(); + } + + @Override + public void disposeStorageLocation() throws IOException { + try { + wrapped.disposeStorageLocation(); + } catch (Exception ex) { + LOG.debug( + "We could not delete the storage location: {} in CLAIM restore mode. It is" + + " most probably because of shared files still being used by newer" + + " checkpoints", Review Comment: This is the case for native savepoints. Native "incremental" RocksDB savepoints place all files in a single savepoint folder. They do not place shared files in the shared folder and thus they can prevent deleting the savepoint folder. -- 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: issues-unsubscr...@flink.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org