diff --git a/tools/db_crashtest.py b/tools/db_crashtest.py index ded789481..185daec69 100644 --- a/tools/db_crashtest.py +++ b/tools/db_crashtest.py @@ -82,6 +82,8 @@ default_params = { "recycle_log_file_num": lambda: random.randint(0, 1), "reopen": 20, "snapshot_hold_ops": 100000, + "sst_file_manager_bytes_per_sec": lambda: random.choice([0, 104857600]), + "sst_file_manager_bytes_per_truncate": lambda: random.choice([0, 1048576]), "long_running_snapshots": lambda: random.randint(0, 1), "subcompactions": lambda: random.randint(1, 4), "target_file_size_base": 2097152, @@ -281,6 +283,8 @@ def finalize_and_sanitize(src_params): if dest_params.get("atomic_flush", 0) == 1: # disable pipelined write when atomic flush is used. dest_params["enable_pipelined_write"] = 0 + if dest_params.get("sst_file_manager_bytes_per_sec", 0) == 0: + dest_params["sst_file_manager_bytes_per_truncate"] = 0 if dest_params.get("enable_compaction_filter", 0) == 1: # Compaction filter is incompatible with snapshots. Need to avoid taking # snapshots, as well as avoid operations that use snapshots for