Skip to content

Commit

Permalink
changefeedccl: job-level retry when error message is about draining
Browse files Browse the repository at this point in the history
See #https://github.com/cockroachlabs/support/issues/1839. The flow
retryable error marker doesn't survive every path by which it can
bubble up, so just look for the single word "draining" as false positives
are much better than false negatives.

Release note (enterprise change): Fixed a bug that could cause changefeeds to fail during a rolling restart.
  • Loading branch information
HonoreDB committed Oct 25, 2022
1 parent 655bde2 commit 531232c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pkg/ccl/changefeedccl/changefeedbase/errors.go
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,9 @@ func IsRetryableError(err error) bool {
// that we can't recover the structure and we have to rely on this
// unfortunate string comparison.
errStr := err.Error()
if strings.Contains(errStr, retryableErrorString) || strings.Contains(errStr, kvcoord.SendErrorString) {
if strings.Contains(errStr, retryableErrorString) ||
strings.Contains(errStr, kvcoord.SendErrorString) ||
strings.Contains(errStr, "draining") {
return true
}

Expand Down

0 comments on commit 531232c

Please sign in to comment.