mirror of
https://github.com/scylladb/scylladb.git
synced 2026-05-29 11:10:40 +00:00
Scrub compaction in segregate mode can split the input sstable into as many as hundreds or even thousands of output sstables in the extreme case. But even at a few dozen output sstables, most of these will only have a few partitions with a few rows. These sstables however will still have their bloom filter allocated according to the original partition-count estimate, causing memory bloat or even OOM in the extreme case. This patch solves this by aggressively adjusting the partition count downwards after the second bucket has been created. Each subsequent bucket will halve the partition estimate, which will quickly reach 1. Fixes: #9463 Closes #9464