diff --git a/snuba/clickhouse/native.py b/snuba/clickhouse/native.py index 0ef5c49530..6baf267861 100644 --- a/snuba/clickhouse/native.py +++ b/snuba/clickhouse/native.py @@ -148,8 +148,8 @@ def execute_robust( attempts, (infinite in the case of too many simultaneous queries errors) and wait a second between retries. - This is used by the writer, which needs to either complete its current - write successfully or else quit altogether. Note that each retry in this + This is by components which need to either complete their current + query successfully or else quit altogether. Note that each retry in this loop will be doubled by the retry in execute() """ attempts_remaining = 3 @@ -168,7 +168,7 @@ def execute_robust( except (errors.NetworkError, errors.SocketTimeoutError, EOFError) as e: # Try 3 times on connection issues. logger.warning( - "Write to ClickHouse failed: %s (%d tries left)", + "ClickHouse query execution failed: %s (%d tries left)", str(e), attempts_remaining, ) @@ -181,7 +181,9 @@ def execute_robust( time.sleep(1) continue except errors.ServerException as e: - logger.warning("Write to ClickHouse failed: %s (retrying)", str(e)) + logger.warning( + "ClickHouse query execution failed: %s (retrying)", str(e) + ) if e.code == errors.ErrorCodes.TOO_MANY_SIMULTANEOUS_QUERIES: # Try forever if the server is overloaded. sleep_seconds = state.get_config(