Skip to content

Commit

Permalink
EIO is now non retriable error (#2275)
Browse files Browse the repository at this point in the history
* EIO is now non retriable error

* Review fixes
  • Loading branch information
komarevtsev-d authored Oct 15, 2024
1 parent c4f1132 commit 116fa80
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions cloud/storage/core/libs/common/error.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,16 @@ EErrorKind GetErrorKind(const NProto::TError& e)
return EErrorKind::ErrorRetriable;
}

// FACILITY_SYSTEM error codes are obtained from "errno". The list of all
// possible errors: contrib/libs/linux-headers/asm-generic/errno-base.h
if (FACILITY_FROM_CODE(code) == FACILITY_SYSTEM) {
// system/network errors should be retriable
return EErrorKind::ErrorRetriable;
switch (STATUS_FROM_CODE(code)) {
case EIO:
return EErrorKind::ErrorFatal;
default:
// system/network errors should be retriable
return EErrorKind::ErrorRetriable;
}
}

if (FACILITY_FROM_CODE(code) == FACILITY_KIKIMR) {
Expand Down

0 comments on commit 116fa80

Please sign in to comment.