Skip to content

Commit

Permalink
[improve][misc] Set format_version=5, checksum=kxxHash in Bookkeeper …
Browse files Browse the repository at this point in the history
…RocksDB configs (apache#23175)
  • Loading branch information
lhotari committed Aug 16, 2024
1 parent 3053b64 commit 576666d
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 8 deletions.
9 changes: 8 additions & 1 deletion conf/bookkeeper.conf
Original file line number Diff line number Diff line change
Expand Up @@ -658,7 +658,7 @@ diskCheckInterval=10000
#############################################################################

# Metadata service uri that bookkeeper uses for loading the corresponding metadata driver and resolving its metadata service location
# Examples:
# Examples:
# - metadataServiceUri=zk+hierarchical://my-zk-1:2181/ledgers
# - metadataServiceUri=etcd+hierarchical:http://my-etcd:2379
# - metadataServiceUri=metadata-store:zk:my-zk-1:2281
Expand Down Expand Up @@ -761,13 +761,20 @@ dbStorage_readAheadCacheBatchSize=1000
## DbLedgerStorage uses RocksDB to store the indexes from
## (ledgerId, entryId) -> (entryLog, offset)

# These settings are ignored since Pulsar 2.11 / Bookkeeper 4.15
# NOTICE: The settings in conf/default_rocksdb.conf, conf/entry_location_rocksdb.conf and
# conf/ledger_metadata_rocksdb.conf files are primarily used to configure RocksDB
# settings. dbStorage_rocksDB_* config keys are ignored.

# Size of RocksDB block-cache. For best performance, this cache
# should be big enough to hold a significant portion of the index
# database which can reach ~2GB in some cases
# Default is to use 10% of the direct memory size
# These settings are ignored since Pulsar 2.11 / Bookkeeper 4.15
dbStorage_rocksDB_blockCacheSize=

# Other RocksDB specific tunables
# These settings are ignored since Pulsar 2.11 / Bookkeeper 4.15
dbStorage_rocksDB_writeBufferSizeMB=64
dbStorage_rocksDB_sstSizeInMB=64
dbStorage_rocksDB_blockSize=65536
Expand Down
11 changes: 9 additions & 2 deletions conf/default_rocksdb.conf
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,14 @@
info_log_level=INFO_LEVEL
# set by jni: options.setKeepLogFileNum
keep_log_file_num=30
# set by jni: options.setLogFileTimeToRoll
log_file_time_to_roll=86400

[CFOptions "default"]
# set by jni: options.setLogFileTimeToRoll
log_file_time_to_roll=86400
#no default setting in CFOptions

[TableOptions/BlockBasedTable "default"]
# set by jni: tableOptions.setFormatVersion
format_version=5
# set by jni: tableOptions.setChecksumType
checksum=kxxHash
6 changes: 3 additions & 3 deletions conf/entry_location_rocksdb.conf
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
# set by jni: options.setLogFileTimeToRoll
log_file_time_to_roll=86400
# set by jni: options.setMaxBackgroundJobs or options.setIncreaseParallelism
max_background_jobs=2
max_background_jobs=32
# set by jni: options.setMaxSubcompactions
max_subcompactions=1
# set by jni: options.setMaxTotalWalSize
Expand Down Expand Up @@ -61,10 +61,10 @@
# set by jni: tableOptions.setBlockCache
block_cache=206150041
# set by jni: tableOptions.setFormatVersion
format_version=2
format_version=5
# set by jni: tableOptions.setChecksumType
checksum=kxxHash
# set by jni: tableOptions.setFilterPolicy, bloomfilter:[bits_per_key]:[use_block_based_builder]
filter_policy=rocksdb.BloomFilter:10:false
# set by jni: tableOptions.setCacheIndexAndFilterBlocks
cache_index_and_filter_blocks=true
cache_index_and_filter_blocks=true
11 changes: 9 additions & 2 deletions conf/ledger_metadata_rocksdb.conf
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,14 @@
info_log_level=INFO_LEVEL
# set by jni: options.setKeepLogFileNum
keep_log_file_num=30
# set by jni: options.setLogFileTimeToRoll
log_file_time_to_roll=86400

[CFOptions "default"]
# set by jni: options.setLogFileTimeToRoll
log_file_time_to_roll=86400
#no default setting in CFOptions

[TableOptions/BlockBasedTable "default"]
# set by jni: tableOptions.setFormatVersion
format_version=5
# set by jni: tableOptions.setChecksumType
checksum=kxxHash

0 comments on commit 576666d

Please sign in to comment.