Merge pull request #68666 from ClickHouse/fix-02293

Improve `02293_http_header_full_summary_without_progress` logging
This commit is contained in:
Konstantin Bogdanov 2024-08-21 23:22:32 +00:00 committed by GitHub
commit 5fdb881987
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -6,8 +6,17 @@ CURDIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
. "$CURDIR"/../shell_config.sh
# Sanity check to ensure that the server is up and running
for _ in {1..10}; do
echo 'SELECT 1' | ${CLICKHOUSE_CURL_COMMAND} -s "${CLICKHOUSE_URL}" --data-binary @- > /dev/null
if [ $? -eq 0 ]; then
break
fi
sleep 1
done
CURL_OUTPUT=$(echo 'SELECT 1 + sleepEachRow(0.00002) FROM numbers(100000)' | \
${CLICKHOUSE_CURL_COMMAND} -vsS "${CLICKHOUSE_URL}&wait_end_of_query=1&send_progress_in_http_headers=0&max_execution_time=1" --data-binary @- 2>&1)
${CLICKHOUSE_CURL_COMMAND} --max-time 3 -vsS "${CLICKHOUSE_URL}&wait_end_of_query=1&send_progress_in_http_headers=0&max_execution_time=1" --data-binary @- 2>&1)
READ_ROWS=$(echo "${CURL_OUTPUT}" | \
grep 'X-ClickHouse-Summary' | \
@ -20,6 +29,7 @@ then
echo "Read rows in summary is not zero"
else
echo "Read rows in summary is zero!"
echo "${CURL_OUTPUT}"
fi
# Check that the response code is correct too