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

Sam Tunnicliffe commented on CASSANDRA-9921:
--------------------------------------------

There are two things wrong here {{CreateIndexStatement}} needs to be updated to 
be view-aware. That is, it needs to check if the table the index is for is a 
view and call {{MigrationManager::announceViewUpdate}}, rather than 
{{MigrationManager::announceColumnFamilyUpdate}}.

Second, reading and writing of view metadata in {{SchemaKeyspace}} needs to 
handle the index definitions in {{ViewDefintion.metadata.indexes}}.

I've pushed a fix [here|https://github.com/beobal/cassandra/tree/9921-2i-3.0] 
which adds both of these and all the view dtests are passing locally except the 
ones which should've been updated when {{system_schema.materialized_views}} was 
renamed. Pull request to fix those 
[here|https://github.com/riptano/cassandra-dtest/pull/558] . 

I'm not sure if these are already known issue but there are a couple of 
problems with cqlsh:
* The {{DESCRIBE}} output doesn't include any indexes on views. I guess this is 
expected at the moment as I don't see anything in the driver to handle it.
* {{SELECT...FROM <view>}} is erroring with {{Column family '<view>' not 
found}}. This seems to be a cqlsh bug as queries direct from the driver work 
fine.

CI Tests:
* [3.0 
testall|http://cassci.datastax.com/view/Dev/view/beobal/job/beobal-9921-2i-3.0-testall/]
* [3.0 
dtest|http://cassci.datastax.com/view/Dev/view/beobal/job/beobal-9921-2i-trunk-dtest/]
* [trunk 
testall|http://cassci.datastax.com/view/Dev/view/beobal/job/beobal-9921-2i-trunk-testall/]
* [trunk 
dtest|http://cassci.datastax.com/view/Dev/view/beobal/job/beobal-9921-2i-trunk-dtest/]



> Combine MV schema definition with MV table definition
> -----------------------------------------------------
>
>                 Key: CASSANDRA-9921
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-9921
>             Project: Cassandra
>          Issue Type: Improvement
>            Reporter: Carl Yeksigian
>            Assignee: Carl Yeksigian
>              Labels: client-impacting, materializedviews
>             Fix For: 3.0.0 rc1
>
>         Attachments: 9921-unit-test.txt
>
>
> Prevent MV from reusing {{system_schema.tables}} and instead move those 
> properties into the {{system_schema.materializedviews}} table to keep them 
> separate entities.



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

Reply via email to