-
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
Support for hex & shard in vindex query #7044
Conversation
Signed-off-by: Alex Charis <acharis@hubspot.com> Signed-off-by: Jacques Grove <aquarapid@gmail.com>
you cannot extract that column by itself. Fix tests Signed-off-by: Jacques Grove <aquarapid@gmail.com>
ef267a9
to
34718e7
Compare
cc: #4501 |
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.
LGTM
Any reason for keeping it in draft mode?
Only reason I left in draft was to see if anyone had an opinion/idea around the '0' vs '-' shard naming thing. |
I think that is fine for now. I can't find the reference but @sougou had stated that |
This is awesome! |
This uses #6260 as a base, see that for history.
Few things:
hex(keyspace_id)
->hex_keyspace_id
, otherwise you cannot select it as it's own column (the sql parser will think you're trying to apply a function)hex_keyspace_id
values without0x
prefixes, following the MySQLHEX()
convention.0
instead of-
, you will receive-
back as your shard "range". You will have to then convert this back to0
as if you want to go ahead and use it to target a shard.As an example using our local
101_initial_cluster.sh
cluster example:commerce
keyspace: