• A
    Delete temp OPTIONS file on failure to write it (#11423) · 2084cdf2
    anand76 提交于
    Summary:
    When the DB is opened, RocksDB creates a temp OPTIONS file, writes the current options to it, and renames it. In case of a failure, the temp file is left behind, and is not deleted by PurgeObsoleteFiles(). Fix this by explicitly deleting the temp file if writing to it or renaming it fails.
    
    Pull Request resolved: https://github.com/facebook/rocksdb/pull/11423
    
    Test Plan: Add a unit test
    
    Reviewed By: akankshamahajan15
    
    Differential Revision: D45540454
    
    Pulled By: anand1976
    
    fbshipit-source-id: 47facdc30d8cc5667036312d04b21d3fc253c92e
    2084cdf2
db_options_test.cc 46.6 KB