-
Notifications
You must be signed in to change notification settings - Fork 70
Conditionally query scylla_tables for table metadata #580
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
Conditionally query scylla_tables for table metadata #580
Conversation
|
Typo: Condtionalty in subject. |
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.
Pull Request Overview
This PR conditionally queries the scylla_tables system table only when connected to ScyllaDB, improving compatibility when using the gocql driver with upstream Cassandra. Previously, the driver would always attempt to query both system_schema.tables and system_schema.scylla_tables regardless of the database type.
- Added conditional logic to skip ScyllaDB-specific table queries when connected to Cassandra
- Updated comment to clarify that
scylla_tablesis only queried for ScyllaDB connections
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
b197e53 to
85d3795
Compare
|
@mykaul @dkropachev fixed |
|
@dkropachev any insight on the failed workflow? EDIT: found it github.com/gocql/gocql.(*Conn).getScyllaSupported(...)
/home/runner/work/gocql/gocql/conn.go:260
github.com/gocql/gocql.(*Conn).isScyllaConn(...)
/home/runner/work/gocql/gocql/scylla.go:286
github.com/gocql/gocql.getTableMetadata(0xc00019e408, {0xa6401d, 0x6})EDIT#2: How would I reproduce the error? are there changes required elsewhere in the code? |
|
Ok, thought there was something else, I'll fix it |
85d3795 to
a977802
Compare
When using scylladb/gocql with upstream Cassandra, the driver queries system_schema.tables to get table metadata. When using scylladb/gocql with ScyllaDB, the driver should also query system_schema.scylla_tables. Closes scylladb#579
a977802 to
5934195
Compare
|
Hi @mykaul , wanted to check in on this, since its merged, when is it going to be released? |
I hope soon, since we already have 60 PRs since last release (v1.15.3...master ). I assume we'd want to complete few additional items (#592 for example) Yes, we always update other projects using our Go driver when we release a new driver. |
|
We will release it soon |
When using scylladb/gocql with upstream Cassandra, the driver queries system_schema.tables to get
table metadata.
When using scylladb/gocql with ScyllaDB, the
driver should also query system_schema.scylla_tables.
Closes #579