-
Notifications
You must be signed in to change notification settings - Fork 68
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
scylla_node: add support to run scylla types
tool
#621
Conversation
ccmlib/scylla_node.py
Outdated
Raises: subprocess.CalledProcessError if scylla-types serialize returns a non-zero exit code. | ||
|
||
""" | ||
if len(values) > len(types): |
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.
What about using a dict? That way it cannot get mismatched
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.
@pehala We cannot use a dict because we need to allow duplicate keys.
I tried using List[Tuple[str, str]], but if prefixable_compounds is set to True, the length of values can be less than the length of types and the existing code seemed more user friendly for such cases. So, I have left it as it is.
226bd0b
to
448cc7e
Compare
448cc7e
to
9dc7503
Compare
Changelog V2 :
|
types
tool and actionsscylla types
tool
e6cace6
to
321d730
Compare
5bf8d76
to
2c18d02
Compare
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, one nit remaining.
This PR implements the `run_scylla_types` method in the ScyllaNode class to run the `types` tool. Also added a new class, ScyllaType to allow callers to define the type that is being sent to the types tool. This is required by scylladb/scylla-dtest#5093 to deduce shards of the partition keys. Refs scylladb/scylladb#18011 Signed-off-by: Lakshmi Narayanan Sreethar <[email protected]>
2c18d02
to
aed75ab
Compare
@fruch please review/merge. |
This PR implements the
run_scylla_types
method in the ScyllaNode classto run the
types
tool. Also added a new class, ScyllaKeyType to allowcallers to define the key type that is being sent to the types tool.
This is required by scylladb/scylla-dtest#5093 to deduce shards of the
partition keys.
Refs scylladb/scylladb#18011