Skip to content

Update GetBlockBasedTableOptionsFromMap docs for filter_policy and block_cache_compressed - #15418

Open
fjvbn2003 wants to merge 1 commit into
meta:mainfrom
fjvbn2003:docs-filter-policy-string
Open

fjvbn2003 wants to merge 1 commit into
meta:mainfrom
fjvbn2003:docs-filter-policy-string

Conversation

@fjvbn2003

Copy link
Copy Markdown

Summary

The comment that explains how to set filter_policy and block_cache by string in GetBlockBasedTableOptionsFromMap() (include/rocksdb/convenience.h, with a copy in table/block_based/block_based_table_factory.cc) still describes behavior from before RocksDB 7.0 and 8.0:

  • It documents "bloomfilter:[bits_per_key]:[use_block_based_builder]" and gives "bloomfilter:4:true" as an example "with use_block_based_builder enabled". Since 7.0 the second field is ignored (filter_policy.h: "As of RocksDB 7.0, the use_block_based_builder parameter is ignored"), and options_test.cc already asserts that bloomfilter:4:true gives the same policy as bloomfilter:4.
  • It says Bloom is the only supported filter policy. "ribbonfilter:[bits_per_key]" and "ribbonfilter:[bits_per_key]:[bloom_before_level]" are also accepted (registered in RegisterBuiltinFilterPolicies, covered by options_test.cc).
  • It lists block_cache_compressed next to block_cache. That option was removed and is now parsed as kDeprecated, which means it is accepted and ignored.

This PR updates both copies of the comment: it drops the boolean from the Bloom syntax and example, documents the Ribbon syntax, and notes that block_cache_compressed is ignored. Only comments change, not code.

Test Plan

Comments only. I checked each statement against table/block_based/filter_policy.cc, table/block_based/block_based_table_factory.cc and the existing assertions in options/options_test.cc (OptionsTest, GetBlockBasedTableOptionsFromString). I did not build RocksDB for this change.

This change was prepared with the help of an AI assistant (Claude); I reviewed and verified it.

🤖 Generated with Claude Code

…ock_cache_compressed

The comment still describes behaviour from before 7.0: the third
"bloomfilter" field is ignored now, "ribbonfilter" is accepted, and
block_cache_compressed is deprecated and has no effect.

Signed-off-by: YoungjuKim <[email protected]>
@meta-cla meta-cla Bot added the CLA Signed label Oct 17, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant