diff options
| author | hiddenpath <[email protected]> | 2025-02-20 21:03:03 +0300 |
|---|---|---|
| committer | hiddenpath <[email protected]> | 2025-02-20 22:13:49 +0300 |
| commit | 2514a84c15eb175f940385fb8e109d8330827b8b (patch) | |
| tree | 80d7ec158812c7ae68b34a8df1f5f193eec9e11b /yt/cpp/mapreduce/http/http.cpp | |
| parent | 26aea1d6bd2c2d51b8ba765beab156218ee64c19 (diff) | |
, YT-24294: Fix retry of 503 http code error without X-Yt-Error
commit_hash:a79152834c521c5dfea79b8a0b1af221078fb108
Diffstat (limited to 'yt/cpp/mapreduce/http/http.cpp')
| -rw-r--r-- | yt/cpp/mapreduce/http/http.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/yt/cpp/mapreduce/http/http.cpp b/yt/cpp/mapreduce/http/http.cpp index 47b9859605a..ae84926a2f3 100644 --- a/yt/cpp/mapreduce/http/http.cpp +++ b/yt/cpp/mapreduce/http/http.cpp @@ -783,6 +783,10 @@ THttpResponse::THttpResponse( logAndSetError(NClusterErrorCodes::NRpc::Unavailable, ::TStringBuilder() << "internal error in proxy " << Context_.HostName); break; + case 503: + logAndSetError(NClusterErrorCodes::NBus::TransportError, "service unavailable"); + break; + default: { TStringStream httpHeaders; httpHeaders << "HTTP headers ("; @@ -801,9 +805,6 @@ THttpResponse::THttpResponse( if (auto parsedResponse = ParseError(HttpInput_->Headers())) { ErrorResponse_ = parsedResponse.GetRef(); - if (HttpCode_ == 503) { - ExtendGenericError(*ErrorResponse_, NClusterErrorCodes::NBus::TransportError, "transport error"); - } } else { ErrorResponse_ = TErrorResponse(TYtError(errorString + " - X-YT-Error is missing in headers"), Context_.RequestId); } |
