facebook / rocksdb

A library that provides an embeddable, persistent key-value store for fast storage.
http://rocksdb.org
GNU General Public License v2.0
27.83k stars 6.2k forks source link

Revert back to previous ReadAsync error injection #12811

Closed hx235 closed 1 week ago

hx235 commented 1 week ago

Context/Summary: https://github.com/facebook/rocksdb/pull/12713 adjusted the error injection in ReadAsync. See original behavior here https://github.com/facebook/rocksdb/blob/71f9e6b5b36e3223e8dba29df75e4e5008818d16/utilities/fault_injection_fs.cc#L456-L484

The PR returns the injected error instead of the ReadAsync() status. It also allows cb to be call in TestFSRandomAccessFile layer when ReadAsync() and the cb can called within FSRandomAccessFile layer so cb can be double called. It appears to be the root-cause of the following frequent errorAddressSanitizer: heap-use-after-free on rocksdb::RandomAccessFileReader::ReadAsync though I don't have a confirmed repro yet. Considering this change to mostly revert to previous behavior, it should be safe to proceed anyway.

Test: Monitor CI

facebook-github-bot commented 1 week ago

@hx235 has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot commented 1 week ago

@hx235 has updated the pull request. You must reimport the pull request before landing.

facebook-github-bot commented 1 week ago

@hx235 has updated the pull request. You must reimport the pull request before landing.

facebook-github-bot commented 1 week ago

@hx235 has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot commented 1 week ago

@hx235 has updated the pull request. You must reimport the pull request before landing.

facebook-github-bot commented 1 week ago

@hx235 has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

facebook-github-bot commented 1 week ago

@hx235 merged this pull request in facebook/rocksdb@41c6b4549ab0dccfb15b7af038f7803cbe8c5f23.