rocksdb/db/db_impl
Yu Zhang d12aaf23ca Fix file deletions in DestroyDB not rate limited (#12891)
Summary:
Make `DestroyDB` slowly delete files if it's configured and enabled via `SstFileManager`.

It's currently not available mainly because of DeleteScheduler's logic related to tracked total_size_ and total_trash_size_. These accounting and logic should not be applied to `DestroyDB`. This PR adds a `DeleteUnaccountedDBFile` util for this purpose which deletes files without accounting it.  This util also supports assigning a file to a specified trash bucket so that user can later wait for a specific trash bucket to be empty. For `DestroyDB`, files with more than 1 hard links will be deleted immediately.

Pull Request resolved: https://github.com/facebook/rocksdb/pull/12891

Test Plan: Added unit tests, existing tests.

Reviewed By: anand1976

Differential Revision: D60300220

Pulled By: jowlyzhang

fbshipit-source-id: 8b18109a177a3a9532f6dc2e40e08310c08ca3c7
2024-08-02 19:31:55 -07:00
..
compacted_db_impl.cc
compacted_db_impl.h
db_impl.cc Fix file deletions in DestroyDB not rate limited (#12891) 2024-08-02 19:31:55 -07:00
db_impl.h Fix file deletions in DestroyDB not rate limited (#12891) 2024-08-02 19:31:55 -07:00
db_impl_compaction_flush.cc Fix duplicate WAL entries caused by write after error recovery (#12873) 2024-07-22 12:40:25 -07:00
db_impl_debug.cc Fix file deletions in DestroyDB not rate limited (#12891) 2024-08-02 19:31:55 -07:00
db_impl_experimental.cc
db_impl_files.cc Ensure Close() before LinkFile() for WALs in Checkpoint (#12734) 2024-06-12 11:48:45 -07:00
db_impl_follower.cc
db_impl_follower.h
db_impl_open.cc Support ingesting SST files generated by a live DB (#12750) 2024-07-19 16:14:54 -07:00
db_impl_readonly.cc
db_impl_readonly.h
db_impl_secondary.cc
db_impl_secondary.h
db_impl_write.cc Fix a data race affecting the background error status (#12910) 2024-08-02 14:11:08 -07:00