You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Sylvain Lebresne (JIRA)" <ji...@apache.org> on 2012/04/26 12:41:17 UTC

[jira] [Updated] (CASSANDRA-4192) CQL3: fix index dropping and assign default name if none provided at index creation

     [ https://issues.apache.org/jira/browse/CASSANDRA-4192?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Sylvain Lebresne updated CASSANDRA-4192:
----------------------------------------

    Attachment: 4192.txt

Patch attached fixes the two issues above. For the second one, it makes sure CREATE INDEX always assign a name to the index. If none is provided, it assign a default one based on the column family name and column name (making sure that 1) the index name is valid and 2) the name is unique). The patch also make sure one cannot create 2 index with the same name, as DROP would have a random behavior in that case.

Note that is probably other way to deal with those problems, yet I'm not sure it's worth getting much more fancy than that.
                
> CQL3: fix index dropping and assign default name if none provided at index creation
> -----------------------------------------------------------------------------------
>
>                 Key: CASSANDRA-4192
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-4192
>             Project: Cassandra
>          Issue Type: Bug
>          Components: API
>    Affects Versions: 1.1.0
>            Reporter: Sylvain Lebresne
>            Assignee: Sylvain Lebresne
>              Labels: cql3
>             Fix For: 1.1.1
>
>         Attachments: 4192.txt
>
>
> This ticket proposes to fix two problems of CQL3 index handling:
> # DROP INDEX is broken (because the code forgot to clone the metadata before doing modification which break the schema update path)
> # If an index is created with a name (which CREATE INDEX allow), there is no way to drop the index (note that we will internally assign a name to the index ColumnFamilyStore, but we don't assign a name in the ColumnDefinition object, which is the only one checked by DROP INDEX).

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira