Files
zeekay 9a90943b8f merge: ClickHouse 26.7.1.1315-stable into datastore — preserve debrand
13,838 upstream commits, forward from the 26.6.1.1 fork point. 129 conflicts:
37 resolved mechanically (take upstream's file, re-apply the brand sweep) and
92 by hand where our fork and upstream had both changed the same code.

The rule throughout: upstream owns the engine, we own the naming and a small set
of deliberate deviations. Never resolve by discarding an upstream change — a
dropped rename or a missed new parameter becomes a compile error a thousand
files away.

Deviations verified intact after the merge:
  ENABLE_XRAY still defaults OFF        (CMakeLists.txt:105)
  X-Datastore-User read by the server   (authenticateUserByHTTP.cpp)
  X-ClickHouse-* in src/                0
  hanzo/research                        present
  system.*_log retention bound          present
  ArrowFlight rip                       held against upstream re-adding it

Two things worth naming, because neither shows up as a conflict:

  src/CMakeLists.txt gained an UNGUARDED
  `add_object_library(datastore_storages_arrowflight Storages/ArrowFlight)` from
  upstream, for a directory our gRPC rip deleted. It sat outside every conflict
  hunk, so a resolver reading only the markers would sail straight past it into
  a CMake configure error. Removed; the Server/ArrowFlight sibling at line 474
  stays because it is inside `if (TARGET ch_contrib::arrow_flight)`.

  The brand sweep had rewritten github.com/ClickHouse/ClickHouse issue links to
  github.com/Datastore/Datastore — a dead host. Those point at upstream's own
  tracker and are restored, alongside the contributors list, sql.clickhouse.com
  and the ClickHouse Inc copyright: attribution is theirs, not ours to rename.

base/glibc-compatibility/memcpy/memcpy.h is deleted, not kept: upstream dropped
it for LLVM-libc's, and our only change to it was a comment rebrand.
2026-07-26 14:47:43 -07:00

58 lines
1.8 KiB
Bash

#!/usr/bin/env bash
set -euo pipefail
CLICKHOUSE_PACKAGE=${CLICKHOUSE_PACKAGE:=""}
CLICKHOUSE_REPO_PATH=${CLICKHOUSE_REPO_PATH:=""}
if [ -z "$CLICKHOUSE_REPO_PATH" ]; then
CLICKHOUSE_REPO_PATH=ch
rm -rf ch ||:
mkdir ch ||:
wget -nv -nd -c "https://datastore-test-reports.s3.amazonaws.com/$PR_TO_TEST/$SHA_TO_TEST/repo/clickhouse_no_subs.tar.gz"
tar -C ch --strip-components=1 -xf clickhouse_no_subs.tar.gz
ls -lath ||:
fi
# Build args as arrays so each flag and its value are passed as separate
# tokens (tools.cli rejects a bundled "--flag value" string as an unknown
# option), and so unset optionals expand to nothing instead of an empty "" arg.
clickhouse_source=(--clickhouse-source "$CLICKHOUSE_PACKAGE")
if [ -n "$WITH_LOCAL_BINARY" ]; then
clickhouse_source=(--clickhouse-source /clickhouse)
fi
# $TESTS_TO_RUN comes from docker
# shellcheck disable=SC2153
tests_count=(--test-count "$TESTS_TO_RUN")
tests_to_run="test-all"
workload=()
if [ -n "$WORKLOAD" ]; then
tests_to_run="test"
workload=(--workload "$WORKLOAD")
tests_count=()
fi
nemesis=()
if [ -n "$NEMESIS" ]; then
nemesis=(--nemesis "$NEMESIS")
fi
rate=()
if [ -n "$RATE" ]; then
rate=(--rate "$RATE")
fi
concurrency=(--concurrency 50)
if [ -n "$CONCURRENCY" ]; then
concurrency=(--concurrency "$CONCURRENCY")
fi
cd "$CLICKHOUSE_REPO_PATH/tests/jepsen.clickhouse"
(lein run server "$tests_to_run" "${workload[@]}" --keeper "$KEEPER_NODE" "${nemesis[@]}" "${rate[@]}" --nodes-file "$NODES_FILE_PATH" --username "$NODES_USERNAME" --logging-json --password "$NODES_PASSWORD" --time-limit "$TIME_LIMIT" "${concurrency[@]}" "${clickhouse_source[@]}" "${tests_count[@]}" --reuse-binary || true) | tee "$TEST_OUTPUT/jepsen_run_all_tests.log"
mv store "$TEST_OUTPUT/"