670a916d01
Summary: Currently, db_stress performs verification by calling `VerifyDb()` at the end of test and optionally before tests start. In case of corruption or incorrect result, it will be too late. This PR adds more verification in two ways. 1. For cf consistency test, each test thread takes a snapshot and verifies every N ops. N is configurable via `-verify_db_one_in`. This option is not supported in other stress tests. 2. For cf consistency test, we use another background thread in which a secondary instance periodically tails the primary (interval is configurable). We verify the secondary. Once an error is detected, we terminate the test and report. This does not affect other stress tests. Test plan (devserver) ``` $./db_stress -test_cf_consistency -verify_db_one_in=0 -ops_per_thread=100000 -continuous_verification_interval=100 $./db_stress -test_cf_consistency -verify_db_one_in=1000 -ops_per_thread=10000 -continuous_verification_interval=0 $make crash_test ``` Pull Request resolved: https://github.com/facebook/rocksdb/pull/6173 Differential Revision: D19047367 Pulled By: riversand963 fbshipit-source-id: aeed584ad71f9310c111445f34975e5ab47a0615 |
||
---|---|---|
.. | ||
batched_ops_stress.cc | ||
cf_consistency_stress.cc | ||
CMakeLists.txt | ||
db_stress_common.cc | ||
db_stress_common.h | ||
db_stress_driver.cc | ||
db_stress_driver.h | ||
db_stress_env_wrapper.h | ||
db_stress_gflags.cc | ||
db_stress_listener.h | ||
db_stress_shared_state.cc | ||
db_stress_shared_state.h | ||
db_stress_stat.h | ||
db_stress_test_base.cc | ||
db_stress_test_base.h | ||
db_stress_tool.cc | ||
db_stress.cc | ||
no_batched_ops_stress.cc |