From 3a1cf1281b94dc672e58b40c9c838e0ec5cb5a5c Mon Sep 17 00:00:00 2001 From: Igor Canadi Date: Thu, 22 May 2014 10:24:24 -0700 Subject: [PATCH] Run FIFO compaction as part of db_crashtest2.py Summary: As title Test Plan: ran it Reviewers: dhruba Reviewed By: dhruba Differential Revision: https://reviews.facebook.net/D18783 --- tools/db_crashtest2.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/tools/db_crashtest2.py b/tools/db_crashtest2.py index 0a12b5a60..3ef383afc 100644 --- a/tools/db_crashtest2.py +++ b/tools/db_crashtest2.py @@ -60,7 +60,7 @@ def main(argv): + str(ops_per_thread) + "\nwrite_buffer_size=" \ + str(write_buf_size) + "\n" - total_check_mode = 3 + total_check_mode = 4 check_mode = 0 while time.time() < exit_time: @@ -75,8 +75,14 @@ def main(argv): # normal run with universal compaction mode additional_opts = "--ops_per_thread=" + str(ops_per_thread) + \ " --compaction_style=1" + elif check_mode == 2: + # normal run with FIFO compaction mode + # ops_per_thread is divided by 5 because FIFO compaction + # style is quite a bit slower on reads with lot of files + additional_opts = "--ops_per_thread=" + str(ops_per_thread / 5) + \ + " --compaction_style=2" else: - # nomral run + # normal run additional_opts = "--ops_per_thread=" + str(ops_per_thread) dbname = tempfile.mkdtemp(prefix='rocksdb_crashtest_') -- GitLab