Details
-
Bug
-
Resolution: Won't Fix
-
Major
-
master
-
None
-
Untriaged
-
Unknown
Description
RocksDBKVStore configuration allow the user to set the following Multi-Thread parameters, e.g.:
rocksdb_options=max_background_flushes=<X>,max_background_compactions=<Y>
|
rocksdb_high_pri_background_threads=<Z>
|
rocksdb_low_pri_background_threads=<Y>
|
'max_background_flushes' and 'max_background_compactions' are per-DB, while 'rocksdb_high_pri_background_threads' and 'rocksdb_low_pri_background_threads' are per-Node / Environment (Flusher Thread Pool and the Compactor Thread Pool respectively).
When none of the parameters above is given, the following default applies:
rocksdb_options=max_background_flushes=1,max_background_compactions=1
|
rocksdb_high_pri_background_threads=<NUM_CORES>
|
rocksdb_low_pri_background_threads=<NUM_CORES>
|
For example, on a 32-CPU Hera node and 4 DBs (i.e., 4 Shards) both the Flusher and the Compactor Thread Pools have size=32, and we should have only 8 Tasks in total ((1 Flusher + 1 Compactor) * 4 DBs). But, RocksDB actually runs up to 32 Threads (see 'hera-32-Threads.png' in attachment).
As opposite, if we give the following parameters we have max 8 Threads running as expected (see 'hera-8-Threads.png' in attachment):
rocksdb_options=max_background_flushes=1,max_background_compactions=1
|
rocksdb_high_pri_background_threads=4
|
rocksdb_low_pri_background_threads=4
|