Skip to content

Commit

Permalink
Merge pull request #61361 from ClickHouse/small_improvement_for_repli…
Browse files Browse the repository at this point in the history
…cation_lib

Tiny improvement for replication.lib
  • Loading branch information
alesapin committed Mar 20, 2024
2 parents 6550b6f + ae0064a commit cc732aa
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion tests/queries/0_stateless/replication.lib
Expand Up @@ -26,12 +26,15 @@ function try_sync_replicas()
done
done

i=0
for t in "${tables_arr[@]}"
do
# Do not start new merges (it can make SYNC a bit faster)
$CLICKHOUSE_CLIENT -q "ALTER TABLE $t MODIFY SETTING max_replicated_merges_in_queue=0"
done

i=0
for t in "${tables_arr[@]}"
do
$CLICKHOUSE_CLIENT --receive_timeout $time_left -q "SYSTEM SYNC REPLICA $t STRICT" || ($CLICKHOUSE_CLIENT -q \
"select 'sync failed, queue:', * from system.replication_queue where database=currentDatabase() and table='$t' order by database, table, node_name" && exit 1) &
pids[${i}]=$!
Expand Down

0 comments on commit cc732aa

Please sign in to comment.