Project: ClickHouse (App Definition and Development / Database)
File: v20.9.1.4585-prestable.md

Added MergeTree settings (`maxreplicatedmergeswithttlinqueue` and `maxnumberofmergeswithttlin_pool`) to control the number of merges with TTL in the background pool and replicated queue. This change breaks compatibility with older versions only if you use delete TTL. Otherwise, replication will stay compatible. You can avoid incompatibility issues if you update all shard replicas at once or execute `SYSTEM STOP TTL MERGES` until you finish the update of all replicas. If you'll get an incompatible entry in the replication queue, first of all, execute `SYSTEM STOP TTL MERGES` and after `ALTER TABLE ... DETACH PARTITION ...` the partition where incompatible TTL merge was assigned. Attach it back on a single replica. (). Add table function `view` which turns an subquery into a table object. This helps passing queries around. For instance, it can be used in remote/cluster table functions. (). Now we can write `select apply(length) apply(max) from widestringtable` to find out the maxium length of all string columns. And the follow two variants are provided too:. (). Add `querystarttimemicroseconds` field to `system.querylog` & `system.querythreadlog` tables. (). Added an aggregate function RankCorrelationSpearman which simply computes a rank correlation coefficient. Continuation of . (). Added database generation by query util. Continuation of . (). Optimize queries with LIMIT/LIMIT BY/ORDER BY for distributed with GROUP BY shardingkey (under optimizeskipunusedshards and optimizedistributedgroupbysharding_key). (). Improvements in StorageRabbitMQ: Added connection and channels failure handling, proper commits, insert failures handling, better exchanges, queue durability and queue resume opportunity, new queue settings. Fixed tests. (). Added Redis requirepass authorization. (). Add precision argument for DateTime type. (). Improve the Kafka engine performance by providing independent thread for each consumer. Separate thread pool for streaming engines (like Kafka). (). Add default compression codec for parts in `system.partlog` with name `defaultcompression_codec`. (). Replace wide integers from boost multiprecision with implementation from https://github.com/cerevra/int. (). Implicitly convert primary key to not null in MaterializeMySQL(Same as MySQL). Fixes . (). Added new setting systemeventsshowzerovalues as proposed in . (). Now obfuscator supports UUID type as proposed in . (). Creating sets for multiple `JOIN` and `IN` in parallel. It may slightly improve performance for queries with several different `IN subquery` expressions.

Now TTLs will be applied during merge if they were not previously materialized. (). MySQL handler returns `OK` for queries like `SET @@var = value`. Such statement is ignored. It is needed because some MySQL drivers send `SET @@` query for setup after handshake #issuecomment-686222422 . (). Speed up server shutdown process if there are ongoing S3 requests. (). Disallow empty time_zone argument in `toStartOf` type of functions. (). ... (). Use std::filesystem::path in ConfigProcessor for concatenating file paths. (). Fix arrayJoin() capturing in lambda (LOGICAL_ERROR). (). Fix GRANT ALL statement when executed on a non-global level. (). Disallows `CODEC` on `ALIAS` column type. Fixes . (). Better check for tuple size in SSD cache complex key external dictionaries. This fixes . (). Fix QueryPlan lifetime (for EXPLAIN PIPELINE graph=1) for queries with nested interpreter. (). Fix exception during ALTER LIVE VIEW query with REFRESH command. (). Fix crash during `ALTER` query for table which was created `AS table_function`. Fixes . (). Stop query execution if exception happened in `PipelineExecutor` itself. This could prevent rare possible query hung. (). Stop query execution if exception happened in `PipelineExecutor` itself. This could prevent rare possible query hung. Continuation of . (). Fix bug which leads to wrong merges assignment if table has partitions with a single part. (). Proxy restart/start/stop/reload of SysVinit to systemd (if it is used). (). Check for array size overflow in `topK` aggregate function. Without this check the user may send a query with carefully crafter parameters that will lead to server crash. This closes . (). Integration tests use default base config. All config changes are explicit with mainconfigs, userconfigs and dictionaries parameters for instance. (). ... (). Fix the logic in backport script. In previous versions it was triggered for any labels of 100% red color. It was strange. (). Fix missed `#include <atomic>`. (). Prepare for build with clang 11. (). Lower binary size in debug build by removing debug info from `Functions`. This is needed only for one internal project in Yandex who is using very old linker. (). Enable ccache by default in cmake if it's found in OS. (). Changelog for 20.7 . (). NO CL ENTRY: 'Revert "Less number of threads in builder"'. ().