1036537c94
Summary: This diff adds support for both soft and hard rate limiting. The following changes are included: 1) Options.rate_limit is renamed to Options.hard_rate_limit. 2) Options.rate_limit_delay_milliseconds is renamed to Options.rate_limit_delay_max_milliseconds. 3) Options.soft_rate_limit is added. 4) If the maximum compaction score is > hard_rate_limit and rate_limit_delay_max_milliseconds == 0, then writes are delayed by 1 ms at a time until the max compaction score falls below hard_rate_limit. 5) If the max compaction score is > soft_rate_limit but <= hard_rate_limit, then writes are delayed by 0-1 ms depending on how close we are to hard_rate_limit. 6) Users can disable 4 by setting hard_rate_limit = 0. They can add a limit to the maximum amount of time waited by setting rate_limit_delay_max_milliseconds > 0. Thus, the old behavior can be preserved by setting soft_rate_limit = 0, which is the default. Test Plan: make -j32 check ./db_stress Reviewers: dhruba, haobo, MarkCallaghan Reviewed By: dhruba CC: leveldb Differential Revision: https://reviews.facebook.net/D12003 |
||
---|---|---|
.. | ||
arena.h | ||
c.h | ||
cache.h | ||
compaction_filter.h | ||
comparator.h | ||
db.h | ||
env.h | ||
filter_policy.h | ||
iterator.h | ||
ldb_tool.h | ||
memtablerep.h | ||
merge_operator.h | ||
options.h | ||
slice.h | ||
statistics.h | ||
status.h | ||
table_builder.h | ||
transaction_log_iterator.h | ||
types.h | ||
write_batch.h |