• Y
    Fail DB::Open() if logger cannot be created (#9984) · 514f0b09
    Yanqin Jin 提交于
    Summary:
    For regular db instance and secondary instance, we return error and refuse to open DB if Logger creation fails.
    
    Our current code allows it, but it is really difficult to debug because
    there will be no LOG files. The same for OPTIONS file, which will be explored in another PR.
    
    Furthermore, Arena::AllocateAligned(size_t bytes, size_t huge_page_size, Logger* logger) has an
    assertion as the following:
    
    ```cpp
    #ifdef MAP_HUGETLB
    if (huge_page_size > 0 && bytes > 0) {
      assert(logger != nullptr);
    }
    #endif
    ```
    
    It can be removed.
    
    Pull Request resolved: https://github.com/facebook/rocksdb/pull/9984
    
    Test Plan: make check
    
    Reviewed By: jay-zhuang
    
    Differential Revision: D36347754
    
    Pulled By: riversand963
    
    fbshipit-source-id: 529798c0511d2eaa2f0fd40cf7e61c4cbc6bc57e
    514f0b09
auto_roll_logger.cc 10.1 KB