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

Jakub Zytka reassigned CASSANDRA-18532:
---------------------------------------

    Assignee: Jakub Zytka

> Cannot read or repair data after dropping a column while one of the nodes is 
> down
> ---------------------------------------------------------------------------------
>
>                 Key: CASSANDRA-18532
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-18532
>             Project: Cassandra
>          Issue Type: Bug
>            Reporter: Jacek Lewandowski
>            Assignee: Jakub Zytka
>            Priority: Normal
>
> When a column is dropped while one of the nodes is down, when the node come 
> back online, repair or querying the data fails.
> This can be reproduced by running the following in-jvm dtest:
> {code:java}
>     @Test
>     public void testDroppingColumnWhenOneNodeIsDown() throws IOException, 
> ExecutionException, InterruptedException
>     {
>         try (Cluster cluster = init(Cluster.build(3).start()))
>         {
>             cluster.schemaChange("create table " + KEYSPACE + ".tab (id int 
> primary key, v1 int, v2 int)");
>             cluster.disableAutoCompaction(KEYSPACE);
>             cluster.coordinator(1).execute("insert into " + KEYSPACE + ".tab 
> (id, v1, v2) VALUES (?, ?, ?)", ConsistencyLevel.ALL, 1, 2, 3);
>             cluster.coordinator(1).execute("insert into " + KEYSPACE + ".tab 
> (id, v1) VALUES (?, ?)", ConsistencyLevel.ALL, 4, 5);
>             cluster.coordinator(1).execute("insert into " + KEYSPACE + ".tab 
> (id, v2) VALUES (?, ?)", ConsistencyLevel.ALL, 6, 7);
>             cluster.get(3).shutdown(true).get();
>             cluster.schemaChangeIgnoringStoppedInstances("alter table " + 
> KEYSPACE + ".tab drop v1");
>             cluster.get(3).startup();
>             cluster.coordinator(1).execute("insert into " + KEYSPACE + ".tab 
> (id, v2) VALUES (?, ?)", ConsistencyLevel.ALL, 1, 9);
>             cluster.coordinator(1).execute("insert into " + KEYSPACE + ".tab 
> (id, v2) VALUES (?, ?)", ConsistencyLevel.ALL, 2, 11);
>             NodeToolResult repairResult = 
> cluster.get(1).nodetoolResult("repair", KEYSPACE, "tab");
>             assertThat(repairResult.getRc()).isZero();
>             SimpleQueryResult rows = 
> cluster.coordinator(1).executeWithResult("select * from " + KEYSPACE + 
> ".tab", ConsistencyLevel.ALL);
>             assertRows(rows.toObjectArrays(), row(1, 9), row(2, 11), row(4, 
> null), row(6, 7));
>             assertRows(cluster.coordinator(1).executeWithResult("select * 
> from " + KEYSPACE + ".tab where id = ?", ConsistencyLevel.ALL, 
> 1).toObjectArrays(), row(1, 9));
>             assertRows(cluster.coordinator(1).executeWithResult("select * 
> from " + KEYSPACE + ".tab where id = ?", ConsistencyLevel.ALL, 
> 2).toObjectArrays(), row(2, 11));
>             assertRows(cluster.coordinator(1).executeWithResult("select * 
> from " + KEYSPACE + ".tab where id = ?", ConsistencyLevel.ALL, 
> 4).toObjectArrays(), row(4, null));
>             assertRows(cluster.coordinator(1).executeWithResult("select * 
> from " + KEYSPACE + ".tab where id = ?", ConsistencyLevel.ALL, 
> 6).toObjectArrays(), row(6, 7));
>         }
>     }
> {code}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to