-
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
Range Query Optimization (For sequential Vindex types) #17342
Range Query Optimization (For sequential Vindex types) #17342
Conversation
Signed-off-by: c-r-dev <[email protected]>
Review ChecklistHello reviewers! 👋 Please follow this checklist when reviewing this Pull Request. General
Tests
Documentation
New flags
If a workflow is added or modified:
Backward compatibility
|
I unchecked this, because CI has not yet run
|
thanks, confirm - modified tests passed consistently locally ( i have run module level unit tests )
Didn't get CI to run locally end to end. Currently working on the CI setup. |
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.
Thank you so much for your contribution!
This looks really good from my POV.
I would love to see a plan test and and one end-to-end test as well. Not sure where the end-to-end test should live. @harshit-gangal probably knows.
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.
We should add plan test that uses Between for Sequential Vindex and Non-Sequential Vindex type
It can be added to go/vt/vtgate/planbuilder/testdata/select_cases.json
thanks @systay and @harshit-gangal for reviewing and sharing feedback, let me incorporate these and get back. Will reach out in case of questions. |
… feedback Signed-off-by: c-r-dev <[email protected]>
Signed-off-by: c-r-dev <[email protected]>
…ema files) Signed-off-by: c-r-dev <[email protected]>
Thanks for the suggestion and pointing me to sample , i have added new test cases with e8593a8 |
thanks @systay , will check these and make next set of changes. |
Signed-off-by: c-r-dev <[email protected]>
…ar to processSingleColumnVindex) Signed-off-by: c-r-dev <[email protected]>
Signed-off-by: c-r-dev <[email protected]>
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #17342 +/- ##
==========================================
+ Coverage 67.60% 67.63% +0.03%
==========================================
Files 1581 1581
Lines 253945 253860 -85
==========================================
+ Hits 171670 171708 +38
+ Misses 82275 82152 -123 ☔ View full report in Codecov by Sentry. |
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.
Changes looks good.
For end to end test. We recently added a way to test the plan tests to also run as e2e test
Look here https://github.com/vitessio/vitess/blob/main/go/test/endtoend/vtgate/plan_tests/plan_e2e_test.go
and the PR that added it #17117
You would have to add filter_cases.json
to the e2e test.
thanks @harshit-gangal , will pull in the changes from #17117 and add test case for |
Thanks , added end-to-end test case for |
thanks @harshit-gangal for reviewing , will incorporate feedback and share and updated version for review. |
Signed-off-by: c-r-dev <[email protected]>
@systay , thanks for the feedback , have worked with @harshit-gangal and got Can you please help to review when you get a chance. |
Signed-off-by: c-r-dev <[email protected]>
thanks @systay for helping to review, have incorporated feedback. Please let me know how it looks. |
Signed-off-by: Andres Taylor <[email protected]>
Description
Queries that specify values in a range (for vindexed column) are sent to all shards, instead of just the shards which contain the values in the range.
Related Issue(s)
Fixes #9808
Checklist
Deployment Notes
Made the change for sequential Vindexes (
binary
andnumeric
)Tests Performed
Added unit tests module level
Included sample schema with two columns (c1 and c2) , c1 is vindexed (type binday) and c2 is not vindexed.
When range queried on column
c1
(vindex column) :When range queried on column
c2
(non vindex column) :