v.24.1Improvement

Adding max_estimated_execution_time Setting to ClickHouse

Adding a setting max_estimated_execution_time to separate max_execution_time and max_estimated_execution_time. #58402 (Zhang Yifan).
Introduces a new setting max_estimated_execution_time to separately control the maximum estimated execution time of queries, distinct from the existing max_execution_time setting.

Why it matters

This feature allows users to enforce limits on the estimated execution time of queries before they are run, helping to prevent long-running queries from consuming excessive resources based on their estimated duration. It provides finer control over query execution management compared to the single max_execution_time setting, which only affects actual runtime.

How to use it

Set the max_estimated_execution_time parameter in your ClickHouse configuration or session to specify the maximum allowed estimated execution time in seconds. Queries with an estimated execution time exceeding this value will be rejected before execution.