v.19.8Improvements
Added Max_parts_in_total Setting for Mergetree Family of Tables (default: 100 000) That Prevents Unsafe Specification of Partition Key #5166
Added max_parts_in_total setting for MergeTree family of tables (default: 100 000) that prevents unsafe specification of partition key #5166. #5171 (alexey-milovidov)Why it matters
This feature addresses the problem of unsafe or inefficient partition key definitions that can cause an excessive number of parts in MergeTree tables. By limiting the total parts, it helps maintain query performance and system stability.How to use it
Users can enable this feature by settingmax_parts_in_total in the server or session settings. The default value is 100,000, and adjusting this limit can help control the maximum allowed parts across all partitions for MergeTree tables.