Hasty Briefsbeta

Bilingual

A Year of Rust in ClickHouse

a year ago
  • #ClickHouse
  • #Programming
  • #Rust
  • Rust integration into ClickHouse was initiated to leverage Rust's strengths without rewriting existing C++ code.
  • Initial Rust component was the BLAKE3 hash function, later replaced by a C++ implementation from LLVM.
  • Subsequent Rust additions included 'skim' for terminal improvements and PRQL as an alternative query language.
  • Delta Kernel integration marked practical use of Rust for Delta Lake support, replacing sketchy C++ code.
  • Challenges included supply chain security, complex C++/Rust interop, panic handling, and sanitizer integration.
  • Cross-compilation and library linking issues were addressed to maintain ClickHouse's portability.
  • Rust's composability with C++ conventions and dependency management required careful handling.
  • Despite challenges, Rust integration is deemed successful, encouraging contributions from Rust developers.