Attempt to fix EAGAIN error

This commit is contained in:
Mikhail f. Shiryaev 2024-09-10 18:06:32 +02:00
parent 6e6e705486
commit 7727b30f5c
No known key found for this signature in database
GPG Key ID: 4B02ED204C7D93F4

View File

@ -188,9 +188,9 @@ function setup_logs_replication
echo -e "Creating remote destination table ${table}_${hash} with statement:" >&2 echo -e "Creating remote destination table ${table}_${hash} with statement:" >&2
echo "::group::${table}" echo "::group::${table}"
cat >&2 <<EOF # there's the only way big "$statement" can be printed without causing EAGAIN error
$statement # cat: write error: Resource temporarily unavailable
EOF echo "$statement" | cat
echo "::endgroup::" echo "::endgroup::"
echo "$statement" | clickhouse-client --database_replicated_initial_query_timeout_sec=10 \ echo "$statement" | clickhouse-client --database_replicated_initial_query_timeout_sec=10 \