ClickHouse Flattens an Expression DAG into Fixed Slots: Replayed Once Per 65 409-Row Block
ClickHouse compiles a SELECT into an ActionsDAG and reuses the sorted plan for every block.
All posts published on this site.
Everything published here, newest first.
ClickHouse compiles a SELECT into an ActionsDAG and reuses the sorted plan for every block.
ClickHouse matches ORDER BY against the sorting key and reads MergeTree parts in key order instead of sorting everything.
Log stores one .bin per column stream plus a __marks.mrk file of (rows, offset) pairs, and truncates files back to a recorded size after a crash.
Kafka offsets are committed only after the block has been written to the views, and a cancelled block is rewound to its start offset and replayed.
Buffer shards writes in RAM, flushes them on a min/max/flush threshold algebra, and restores the block if the destination write fails.