mirror of
https://github.com/scylladb/scylladb.git
synced 2026-04-25 02:50:33 +00:00
Normally, the space overhead for TWCS is 1/N, where is number of windows. But during off-strategy, the overhead is 100% because input sstables cannot be released earlier. Reshaping a TWCS table that takes ~50% of available space can result in system running out of space. That's fixed by restricting every TWCS off-strategy job to 10% of free space in disk. Tables that aren't big will not be penalized with increased write amplification, as all input (disjoint) sstables can still be compacted in a single round. Fixes https://github.com/scylladb/scylladb/issues/16514. (cherry picked from commitb8bd4c51c2) (cherry picked from commit51c7ee889e) (cherry picked from commit0ce8ee03f1) (cherry picked from commitace4e5111e) Refs https://github.com/scylladb/scylladb/pull/18137 note for maintainer: first cleanup (conflicting) patch was removed and doesn't change anything. Closes scylladb/scylladb#19549 * github.com:scylladb/scylladb: compaction: Reduce twcs off-strategy space overhead to 10% of free space compaction: wire storage free space into reshape procedure sstables: Allow to get free space from underlying storage