rest client: Expect context timeouts for locks (#10782)

Add option for rest clients to not mark a remote offline for context timeouts.

This can be used if context timeouts are expected on the call.
This commit is contained in:
Klaus Post
2020-10-29 09:52:11 -07:00
committed by GitHub
parent 6b14c4ab1e
commit e63a44b734
9 changed files with 27 additions and 18 deletions

View File

@@ -42,7 +42,7 @@ func isNetworkError(err error) bool {
return false
}
if nerr, ok := err.(*rest.NetworkError); ok {
return xnet.IsNetworkOrHostDown(nerr.Err)
return xnet.IsNetworkOrHostDown(nerr.Err, false)
}
return false
}