Skip to content

Commit 3da2411

Browse files
authored
Merge pull request ClickHouse#78709 from azat/ci/fix-bug-fix-check
ci: fix bug-fix check (due to new settings added to tests configurations in 25.4)
2 parents 3b2a325 + f2a65f3 commit 3da2411

File tree

3 files changed

+24
-3
lines changed

3 files changed

+24
-3
lines changed
Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,5 @@
11
<clickhouse>
22
<merge_tree>
33
<max_postpone_time_for_failed_mutations_ms>200</max_postpone_time_for_failed_mutations_ms>
4-
<max_postpone_time_for_failed_replicated_fetches_ms>0</max_postpone_time_for_failed_replicated_fetches_ms>
5-
<max_postpone_time_for_failed_replicated_merges_ms>0</max_postpone_time_for_failed_replicated_merges_ms>
6-
<max_postpone_time_for_failed_replicated_tasks_ms>0</max_postpone_time_for_failed_replicated_tasks_ms>
74
</merge_tree>
85
</clickhouse>
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<clickhouse>
2+
<merge_tree>
3+
<max_postpone_time_for_failed_replicated_fetches_ms>0</max_postpone_time_for_failed_replicated_fetches_ms>
4+
<max_postpone_time_for_failed_replicated_merges_ms>0</max_postpone_time_for_failed_replicated_merges_ms>
5+
<max_postpone_time_for_failed_replicated_tasks_ms>0</max_postpone_time_for_failed_replicated_tasks_ms>
6+
</merge_tree>
7+
</clickhouse>

tests/config/install.sh

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,20 @@ while [[ "$#" -gt 0 ]]; do
2626
shift
2727
done
2828

29+
function check_clickhouse_version()
30+
{
31+
local required_version=$1 && shift
32+
# ClickHouse local version 25.4.1.1.
33+
current_version=$(clickhouse --version | awk '{print $NF}')
34+
35+
if [ "$(printf '%s\n' "$required_version" "$current_version" | sort -V | head -n1)" = "$required_version" ]; then
36+
echo "ClickHouse version $current_version is OK (>= $required_version)"
37+
else
38+
echo "ClickHouse version $current_version is too old. Required >= $required_version"
39+
return 1
40+
fi
41+
}
42+
2943
echo "Going to install test configs from $SRC_PATH into $DEST_SERVER_PATH"
3044

3145
mkdir -p $DEST_SERVER_PATH/config.d/
@@ -51,6 +65,9 @@ ln -sf $SRC_PATH/config.d/database_atomic.xml $DEST_SERVER_PATH/config.d/
5165
ln -sf $SRC_PATH/config.d/max_concurrent_queries.xml $DEST_SERVER_PATH/config.d/
5266
ln -sf $SRC_PATH/config.d/merge_tree_settings.xml $DEST_SERVER_PATH/config.d/
5367
ln -sf $SRC_PATH/config.d/backoff_policy.xml $DEST_SERVER_PATH/config.d/
68+
if check_clickhouse_version 25.4; then
69+
ln -sf $SRC_PATH/config.d/backoff_policy_25_4.xml $DEST_SERVER_PATH/config.d/
70+
fi
5471
ln -sf $SRC_PATH/config.d/merge_tree_old_dirs_cleanup.xml $DEST_SERVER_PATH/config.d/
5572
ln -sf $SRC_PATH/config.d/test_cluster_with_incorrect_pw.xml $DEST_SERVER_PATH/config.d/
5673
ln -sf $SRC_PATH/config.d/keeper_port.xml $DEST_SERVER_PATH/config.d/

0 commit comments

Comments
 (0)