ClickHouse Rewrites a Distributed Query for Every Shard: Pruned IN Sets and Broadcast Temporary Tables
ClickHouse rewrites the query tree per shard: pruning by sharding key and shipping temporary tables for GLOBAL IN/JOIN.
ClickHouse rewrites the query tree per shard: pruning by sharding key and shipping temporary tables for GLOBAL IN/JOIN.
Replication is a ZooKeeper log plus a content-hash deduplication check that rides along with the block-number allocation.
ClickHouse’s TCP handler interleaves sending results with reading the next command on a timer, piggybacking logs and progress onto the output stream.
ClickHouse splits CSV into row-aligned chunks with a quote-aware scanner, parses them on separate threads, and reorders them with a ticket ring.
The Native format writes a row count, then for each column its name, type, serialization kind and bulk data — never a row.