Skip to content
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

storage: better error when stores are throttled #35308

Merged
merged 1 commit into from
Mar 5, 2019

Conversation

tbg
Copy link
Member

@tbg tbg commented Mar 1, 2019

This is an annoying blocker during replication, and has also played a
role in test flakes such as #35307.

Release note: None

@tbg tbg requested a review from a team March 1, 2019 12:46
@cockroach-teamcity
Copy link
Member

This change is Reviewable

@tbg tbg force-pushed the fix/throttle-better-error branch from ebd16e8 to 44a9481 Compare March 1, 2019 12:49
Copy link
Collaborator

@petermattis petermattis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:lgtm:

Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained (waiting on @tbg)


pkg/storage/store_snapshot.go, line 755 at r1 (raw file):

			}
			err := &benignError{errors.Errorf("%s: remote declined %s: %s", to, snap, declinedMsg)}
			storePool.throttle(throttleDeclined, declinedMsg, to.StoreID)

Seems like you can generate the err after the call to storePool.throttle in which case you can return &benignError{...}. On the other hand, perhaps you mean to pass in err.Error() here as you do below.

This is an annoying blocker during replication, and has also played a
role in test flakes such as cockroachdb#35307.

Release note: None
@tbg tbg force-pushed the fix/throttle-better-error branch from 44a9481 to 2beec4e Compare March 5, 2019 08:36
@tbg
Copy link
Member Author

tbg commented Mar 5, 2019

Done, TFTR!

bors r=petermattis

craig bot pushed a commit that referenced this pull request Mar 5, 2019
35308: storage: better error when stores are throttled r=petermattis a=tbg

This is an annoying blocker during replication, and has also played a
role in test flakes such as #35307.

Release note: None

Co-authored-by: Tobias Schottdorf <[email protected]>
@craig
Copy link
Contributor

craig bot commented Mar 5, 2019

Build succeeded

@craig craig bot merged commit 2beec4e into cockroachdb:master Mar 5, 2019
@tbg tbg deleted the fix/throttle-better-error branch March 13, 2019 11:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants