fix(workflow): retry a transient read while awaiting a callee
This commit is contained in:
1 parent
4e74ed37b4
commit
455de3d799
4 files changed
+228
-9
No files matched your search
@@ -456,6 +456,11 @@ func unmapError(err error) error {
|
||||
return context.Canceled
|
||||
case codes.DeadlineExceeded:
|
||||
return context.DeadlineExceeded
|
||||
case codes.Unavailable:
|
||||
// Wrap both, so a caller can retry on errors.Is(ErrUnavailable) and a
|
||||
// caller that maps status codes still reads Unavailable through the
|
||||
// chain.
|
||||
return fmt.Errorf("%w: %w", storecontract.ErrUnavailable, err)
|
||||
}
|
||||
if sentinel := sentinelForStatus(st); sentinel != nil {
|
||||
return sentinel
|
||||
|
||||
Reference in new issue
Block a user