-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Wait forever for fatal errors #155
Conversation
pkg/common/helper.go
Outdated
} | ||
func errorMatches(err error, substrings []string) bool { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
newline
&c.getShardLocationBackoff, func(attempt int) (bool, error, int) { | ||
c.currentShardLocation, err = c.getCurrentShardLocation(c.shardID) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
&c.getShardLocationBackoff, func(attempt int) (bool, error, int) { | |
c.currentShardLocation, err = c.getCurrentShardLocation(c.shardID) | |
&c.getShardLocationBackoff, | |
func(attempt int) (bool, error, int) { | |
c.currentShardLocation, err = c.getCurrentShardLocation(c.shardID) |
pkg/common/helper.go
Outdated
|
||
func EngineErrorIsFatal(err error) bool { | ||
var fatalEngineErrorsPartialMatch = []string{ | ||
"Failed to fetch record batches", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not the error from v3io, this is a log the this client prints later.
As the ticket says, you want to retry on:
lookup v3io-webapi: i/o timeout
// if the error is fatal and requires external resolution, | ||
// we don't want to fail; instead, we will inform the user via a log | ||
if common.EngineErrorIsFatal(err) { | ||
// although RetryFunc already logs the error, it logs it as a warning |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It actually doesn't log the error?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lines 71 to 81 in 0d34f11
loggerInstance.WarnWithCtx(ctx, | |
"Context error detected during retries", | |
"ctxErr", ctx.Err(), | |
"previousErr", err, | |
"function", getFunctionName(fn), | |
"attempt", attempt) | |
// return the error if one was provided | |
if err != nil { | |
return err | |
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This warning is for a ctx.Error
, like if an external error happened.
In your case you check the error returned from getCurrentShardLocation
, which isn't handled by the retry func.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@TomerShor right 🤦
i'll remove comment
Jira - https://iguazio.atlassian.net/browse/NUC-340