aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan Engelbrecht <[email protected]>2026-04-13 14:53:20 +0200
committerGitHub Enterprise <[email protected]>2026-04-13 14:53:20 +0200
commit08bb8a8825696f273113491473a6168e6dfda876 (patch)
tree2f473b75e45f19da63f20607e7b53c96ee8f7c80
parentsilence errors due to abort (#950) (diff)
downloadzen-08bb8a8825696f273113491473a6168e6dfda876.tar.xz
zen-08bb8a8825696f273113491473a6168e6dfda876.zip
log curl raw error on retry, add retry on CURLE_PARTIAL_FILE error (#951)
* log curl raw error on retry, add retry on CURLE_PARTIAL_FILE error
-rw-r--r--CHANGELOG.md1
-rw-r--r--src/zenhttp/clients/httpclientcurl.cpp4
2 files changed, 4 insertions, 1 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md
index ea3f62455..c53d5c920 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -23,6 +23,7 @@
- Bugfix: Added logic to shared memory instance state management to ensure unclean shutdown followed by restart with identical pid doesn't lead to errors. Particularly likely to happen when running on k8s
- Improvement: Dashboard service stats panes are now always visible on service pages (projects, cache, builds, workspaces) rather than hidden until data arrives
- Improvement: Updated vendored MinIO test server from RELEASE.2025-07-23 to RELEASE.2025-09-07 (HTTP listener bugfixes, ListObject fix)
+- Improvement: HTTP client retries on `CURLE_PARTIAL_FILE` (truncated response) and logs the raw curl error code on retry
- Bugfix: Dashboard stats tiles no longer flicker on page load when WebSocket updates arrive before all stats are available
- Bugfix: Build storage operations now silence HTTP exceptions on aborted requests instead of logging spurious errors
diff --git a/src/zenhttp/clients/httpclientcurl.cpp b/src/zenhttp/clients/httpclientcurl.cpp
index b9af9bd52..446dd80be 100644
--- a/src/zenhttp/clients/httpclientcurl.cpp
+++ b/src/zenhttp/clients/httpclientcurl.cpp
@@ -443,6 +443,7 @@ CurlHttpClient::ShouldRetry(const CurlResult& Result)
case CURLE_RECV_ERROR:
case CURLE_SEND_ERROR:
case CURLE_OPERATION_TIMEDOUT:
+ case CURLE_PARTIAL_FILE:
return true;
default:
return false;
@@ -489,10 +490,11 @@ CurlHttpClient::DoWithRetry(std::string_view SessionId, std::function<CurlResult
{
if (Result.ErrorCode != CURLE_OK)
{
- ZEN_INFO("Retry (session: {}): HTTP error ({}) '{}' Attempt {}/{}",
+ ZEN_INFO("Retry (session: {}): HTTP error ({}) '{}' (Curl error: {}) Attempt {}/{}",
SessionId,
static_cast<int>(MapCurlError(Result.ErrorCode)),
Result.ErrorMessage,
+ static_cast<int>(Result.ErrorCode),
Attempt,
m_ConnectionSettings.RetryCount + 1);
}