You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Adam Holmberg (JIRA)" <ji...@apache.org> on 2015/03/16 15:31:39 UTC

[jira] [Commented] (CASSANDRA-8005) Server-side DESCRIBE

    [ https://issues.apache.org/jira/browse/CASSANDRA-8005?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14363260#comment-14363260 ] 

Adam Holmberg commented on CASSANDRA-8005:
------------------------------------------

I'm emphatically +1 on this, weighing in as this has emerged as a recurring pain point in Python driver maintenance.

https://datastax-oss.atlassian.net/browse/PYTHON-165
https://datastax-oss.atlassian.net/browse/PYTHON-192
https://datastax-oss.atlassian.net/browse/PYTHON-213

In my opinion, schema metadata is an implementation detail that the server should be able to translate to the API (CQL). Letting the drivers do it is error-prone, and allows for idiosyncrasies like the one in PYTHON192 and PYTHON-213, where the construct is not even expressible in CQL.

While CASSANDRA-6717 may lead to simpler interpretation of a new implementation, drivers will still need to interpret both new and old implementations, instead of letting the server tell it what the metadata means.

Not all drivers support CQL schema export presently, and the ones that do are inconsistent (particularly around edge cases noted above). Having the server output schema CQL would not preclude programmatic access to schema meta tables, but it would remove the need for multiple client interpretations of a server-side model.

> Server-side DESCRIBE
> --------------------
>
>                 Key: CASSANDRA-8005
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-8005
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: API
>            Reporter: Tyler Hobbs
>            Priority: Minor
>              Labels: client-impacting, cql3
>             Fix For: 3.0
>
>
> The various {{DESCRIBE}} commands are currently implemented by cqlsh, and nearly identical implementations exist in many drivers.  There are several motivations for making {{DESCRIBE}} part of the CQL language:
> * Eliminate the (fairly complex) duplicate implementations across drivers and cqlsh
> * Get closer to allowing drivers to not have to fetch the schema tables. (Minor changes to prepared statements are also needed.)
> * Have instantaneous support for new schema features in cqlsh.  (You currently have to update the bundled python driver.)
> * Support writing out schemas where it makes sense.  One good example of this is backups.  You need to restore the schema before restoring data in the case of total loss, so it makes sense to write out the schema alongside snapshots.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)