tablet_picker: keep trying to find a tablet until context expires#6546
Merged
deepthi merged 10 commits intovitessio:masterfrom Aug 14, 2020
Merged
tablet_picker: keep trying to find a tablet until context expires#6546deepthi merged 10 commits intovitessio:masterfrom
deepthi merged 10 commits intovitessio:masterfrom
Conversation
Signed-off-by: deepthi <deepthi@planetscale.com>
Collaborator
Author
|
@sougou can you please review the tests and logging? We don't want to spam the logs but still produce useful information. |
sougou
approved these changes
Aug 6, 2020
Signed-off-by: deepthi <deepthi@planetscale.com>
…teMainflow Signed-off-by: Rohit Nayak <rohit@planetscale.com>
deepthi
commented
Aug 10, 2020
go/vt/discovery/tablet_picker.go
Outdated
| candidates := tp.getMatchingTablets(ctx) | ||
| if len(candidates) == 0 { | ||
| // if no candidates were found, sleep and try again | ||
| log.Infof("No tablet found for streaming, sleeping for %d", tabletPickerRetryDelay) |
Collaborator
Author
There was a problem hiding this comment.
+1. I was planning to add something similar.
Signed-off-by: Rohit Nayak <rohit@planetscale.com>
Signed-off-by: Rohit Nayak <rohit@planetscale.com>
Signed-off-by: Rohit Nayak <rohit@planetscale.com>
Signed-off-by: Rohit Nayak <rohit@planetscale.com>
Signed-off-by: Rohit Nayak <rohit@planetscale.com>
Signed-off-by: Rohit Nayak <rohit@planetscale.com>
Signed-off-by: deepthi <deepthi@planetscale.com>
deepthi
added a commit
to planetscale/vitess
that referenced
this pull request
Aug 14, 2020
…tessio#6546) * tablet_picker: keep trying to find a tablet until context expires Signed-off-by: deepthi <deepthi@planetscale.com> * tablet_picker: keyspace/shard/cells must be provided Signed-off-by: deepthi <deepthi@planetscale.com> * tablet picker: return ks/cell/shard in test result for TestShardMigrateMainflow Signed-off-by: Rohit Nayak <rohit@planetscale.com> * tablet picker: fix wrangler tests by choosing a valid source per-test Signed-off-by: Rohit Nayak <rohit@planetscale.com> * tablet picker: fix worker and testlib tests Signed-off-by: Rohit Nayak <rohit@planetscale.com> * tablet_picker: gofmted Signed-off-by: Rohit Nayak <rohit@planetscale.com> * tablet picker: fix test races Signed-off-by: Rohit Nayak <rohit@planetscale.com> * tablet picker: gofmt Signed-off-by: Rohit Nayak <rohit@planetscale.com> * tablet picker: gofmt Signed-off-by: Rohit Nayak <rohit@planetscale.com> * healthcheck: cleanup test code where we were setting the same flag twice Signed-off-by: deepthi <deepthi@planetscale.com> Co-authored-by: Rohit Nayak <rohit@planetscale.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
There was a bug in the tablet_picker implementation which could cause it to loop forever.
Along with fixing the above problem, this change has a few other improvements
Signed-off-by: deepthi deepthi@planetscale.com