This commit is contained in:
Alexander Tokmakov 2021-08-12 00:29:37 +03:00
parent a2b2e8cb3f
commit 0256e313b3
3 changed files with 8 additions and 7 deletions

View File

@ -641,6 +641,7 @@ def run_tests_array(all_tests_with_params):
status += print_test_time(total_time)
status += " - having stderror:\n{}\n".format(
'\n'.join(stderr.split('\n')[:100]))
status += "\nstdout:\n{}\n".format(stdout)
status += 'Database: ' + testcase_args.testcase_database
elif 'Exception' in stdout:
failures += 1

View File

@ -35,7 +35,7 @@ function wait_for_all_mutations()
fi
if [[ $i -eq 200 ]]; then
echo "Timed out while waiting for mutation to execute!" | tee >(cat >&2)
echo "Timed out while waiting for mutation to execute!"
fi
done

View File

@ -33,12 +33,12 @@ function check_replication_consistency()
FROM merge(currentDatabase(), '$1') GROUP BY _table
)"
res=$?
if ! [ $res -eq 0 ]; then
echo "Replicas have diverged" | tee >(cat >&2)
$CLICKHOUSE_CLIENT -q "select _table, $2, arraySort(groupArrayDistinct(_part)) from merge(currentDatabase(), '$1') group by _table" | tee >(cat >&2)
$CLICKHOUSE_CLIENT -q "select * from system.replication_queue where database=currentDatabase() and table like '$1%'" | tee >(cat >&2)
$CLICKHOUSE_CLIENT -q "select * from system.mutations where database=currentDatabase() and table like '$1%'" | tee >(cat >&2)
$CLICKHOUSE_CLIENT -q "select * from system.parts where database=currentDatabase() and table like '$1%'" | tee >(cat >&2)
if [ $res -ne 0 ]; then
echo "Replicas have diverged"
$CLICKHOUSE_CLIENT -q "select _table, $2, arraySort(groupArrayDistinct(_part)) from merge(currentDatabase(), '$1') group by _table"
$CLICKHOUSE_CLIENT -q "select * from system.replication_queue where database=currentDatabase() and table like '$1%'"
$CLICKHOUSE_CLIENT -q "select * from system.mutations where database=currentDatabase() and table like '$1%'"
$CLICKHOUSE_CLIENT -q "select * from system.parts where database=currentDatabase() and table like '$1%'"
fi
}