Retry more errors from S3

This commit is contained in:
Alexey Milovidov 2024-10-27 00:29:36 +02:00
parent 99161db8fd
commit c58afb753c

View File

@ -645,7 +645,7 @@ Client::doRequestWithRetryNetworkErrors(RequestType & request, RequestFn request
try
{
/// S3 does retries network errors actually.
/// But it is matter when errors occur.
/// But it does matter when errors occur.
/// This code retries a specific case when
/// network error happens when XML document is being read from the response body.
/// Hence, the response body is a stream, network errors are possible at reading.
@ -656,8 +656,9 @@ Client::doRequestWithRetryNetworkErrors(RequestType & request, RequestFn request
/// Requests that expose the response stream as an answer are not retried with that code. E.g. GetObject.
return request_fn_(request_);
}
catch (Poco::Net::ConnectionResetException &)
catch (Poco::Net::NetException &)
{
/// This includes "connection reset", "malformed message", and possibly other exceptions.
if constexpr (IsReadMethod)
{