aboutsummaryrefslogtreecommitdiff
path: root/src/zenhttp/httpclient.cpp
diff options
context:
space:
mode:
authorDan Engelbrecht <[email protected]>2026-03-20 13:44:19 +0100
committerGitHub Enterprise <[email protected]>2026-03-20 13:44:19 +0100
commitd9b614cc8b92667b94d4ec3eb6bb2942d0a0e33f (patch)
tree149703893d865208e6ffdc9f8be7fb00690a546d /src/zenhttp/httpclient.cpp
parentadd hub instance info (#869) (diff)
downloadzen-d9b614cc8b92667b94d4ec3eb6bb2942d0a0e33f.tar.xz
zen-d9b614cc8b92667b94d4ec3eb6bb2942d0a0e33f.zip
auth fail no cache (#871)v5.7.24-pre0v5.7.24
- Bugfix: Retry OIDC token refresh once on failure before propagating the error - Bugfix: Handle HTTP 501 (Not Implemented) from Jupiter as a signal to fall back from multi-range to single-range requests
Diffstat (limited to 'src/zenhttp/httpclient.cpp')
-rw-r--r--src/zenhttp/httpclient.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/zenhttp/httpclient.cpp b/src/zenhttp/httpclient.cpp
index 3e81d4a8a..13c86e9ae 100644
--- a/src/zenhttp/httpclient.cpp
+++ b/src/zenhttp/httpclient.cpp
@@ -128,6 +128,11 @@ HttpClientBase::GetAccessToken()
return m_CachedAccessToken.GetValue();
}
HttpClientAccessToken NewAccessToken = m_ConnectionSettings.AccessTokenProvider.value()();
+ if (!NewAccessToken.IsValid())
+ {
+ ZEN_WARN("HttpClient failed to refresh access token, retrying once");
+ NewAccessToken = m_ConnectionSettings.AccessTokenProvider.value()();
+ }
if (NewAccessToken.IsValid())
{
m_CachedAccessToken = NewAccessToken;