-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
VStream API: allow cells to be specified for picking source tablets to stream from #10294
VStream API: allow cells to be specified for picking source tablets to stream from #10294
Conversation
…or candidates in Signed-off-by: Rohit Nayak <rohit@planetscale.com>
Signed-off-by: Rohit Nayak <rohit@planetscale.com>
I assume this will also work with cell-aliases? |
Yes, because it is just calls the tablet picker with the cell names and we already resolve aliases there. |
Review ChecklistHello reviewers! 👋 Please follow this checklist when reviewing this Pull Request. General
Bug fixes
Non-trivial changes
New/Existing features
Backward compatibility
|
Signed-off-by: Rohit Nayak <rohit@planetscale.com>
Sorry, @rohit-nayak-ps ! Somehow I completely missed this one. I will review in the next few hours. |
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.
I had some questions and nits, but nothing major. Will approve so that you're not blocked if I misunderstood something or you disagree.
Signed-off-by: Rohit Nayak <rohit@planetscale.com>
…o stream from (vitessio#10294) * Add parameter Cells in vstream api flags, for tablet picker to look for candidates in Signed-off-by: Rohit Nayak <rohit@planetscale.com> * Add e2e test for the new Cells vstream flag Signed-off-by: Rohit Nayak <rohit@planetscale.com> * Self-review Signed-off-by: Rohit Nayak <rohit@planetscale.com> * Address review comments Signed-off-by: Rohit Nayak <rohit@planetscale.com> Signed-off-by: Vilius Okockis <vilius.okockis@vinted.com>
…o stream from (vitessio#10294) * Add parameter Cells in vstream api flags, for tablet picker to look for candidates in Signed-off-by: Rohit Nayak <rohit@planetscale.com> * Add e2e test for the new Cells vstream flag Signed-off-by: Rohit Nayak <rohit@planetscale.com> * Self-review Signed-off-by: Rohit Nayak <rohit@planetscale.com> * Address review comments Fix gofmt Signed-off-by: Rohit Nayak <rohit@planetscale.com> Signed-off-by: Vilius Okockis <vilius.okockis@vinted.com>
Description
The VTGate VStreamAPI, internally needs to source data from tablets using the
RowStreamer
andVStreamer
APIs. It uses aTabletPicker
to choose a tablet per shard. If aREPLICA
tablet type is specified, currently the picker looks at tablets in the same cell as the vtgate to choose a replica to source from. However it is possible that there is no replica in the cell of the vtgate one connects to.This PR adds the ability to specify a list of (comma separated) cell names/cell aliases. Instead of changing the API signature we add a new
Cells
field to the VStreamFlags struct for this purpose.Sample usage:
The functionality is validated by a e2e test.
Related Issue(s)
Checklist