Skip to content
Opensource internals
  • Posts

Clickhouse

ClickHouse Prices Distributed Plans in a Cascades Memo: Work, Network and Sequential Cost

Oct 16, 2026 22 min read Jay Hubbert

ClickHouse’s new Cascades optimizer treats a distributed query as a search problem.

ClickhousePerformanceInternalsQuery planningDistributed

Read more →

ClickHouse Starts the Pipeline with One Thread: Work Stealing Queues and Downscaling Under Load

Oct 16, 2026 21 min read Jay Hubbert

ClickHouse doesn’t hand you max_threads threads. It starts with one, measures how much parallel work the pipeline actually creates, and grows the pool only when idle…

ClickhouseInternalsQuery executionConcurrency

Read more →

ClickHouse Packs Short Strings by Size Class: 24 Bytes Fit in Three UInt64s

Oct 16, 2026 14 min read Jay Hubbert

ClickHouse never stores a std::string in a hash table cell. It splits keys into size classes and packs strings of up to 24 bytes into plain integers, so your GROUP BY…

ClickhouseInternalsHash tableStringsPerformance

Read more →

ClickHouse Aggregates Sorted Keys Without a Hash Table: Counting Runs and Pushing LIMIT Down

Oct 16, 2026 16 min read Jay Hubbert

If your table is sorted by the GROUP BY key, ClickHouse can skip the hash table entirely: it counts each contiguous run of equal keys and emits it.

ClickhouseInternalsAggregationPerformance

Read more →

ClickHouse Merges Columns One at a Time: A Byte per Row Caps Merges at 127 Parts

Oct 16, 2026 20 min read Jay Hubbert

ClickHouse’s vertical merge splits a merge into two stages: merge the key and record where each output row came from (one byte per row), then gather each payload column…

ClickhousePerformanceInternalsMerge treeStorage engine

Read more →

← Newer Page 20 of 21 Older →

© 2026 Jay Hubbert · Built with Hugo 0.168.0

RSS ·