cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jonathan Ellis (JIRA)" <>
Subject [jira] [Commented] (CASSANDRA-5064) 'Alter table' when it includes collections makes cqlsh hang
Date Thu, 13 Dec 2012 22:40:12 GMT


Jonathan Ellis commented on CASSANDRA-5064:

This is starting to feel fragile, and I've never been a fan of Table.switchLock/maybeSwitchMemtable
in the first place (even though I wrote it :).

Pushed a different approach to  The first
commit is the important one: we replace Table.switchLock with reference-counted memtables.
 We can then merge DataTracker.[renew|switch]Memtable, change maybeSwitchMemtable to unconditionally
switch (but only flush if there were updates made), and this problem goes away along with
a bunch of other switchLock-related complexity.

Also suspect that an atomic increment is a performance win over ReentrantReadWriteLock, which
is one of the most heavyweight concurrency classes.
> 'Alter table' when it includes collections makes cqlsh hang
> -----------------------------------------------------------
>                 Key: CASSANDRA-5064
>                 URL:
>             Project: Cassandra
>          Issue Type: Bug
>    Affects Versions: 1.2.0 beta 3, 1.2.0
>         Environment: Ubuntu 12.04 LTS
> 3.2.0-23-virtual
>            Reporter: Ryan McGuire
>            Assignee: Sylvain Lebresne
>            Priority: Critical
>             Fix For: 1.2.0
>         Attachments: 5064.txt
> Having just installed 1.2.0-beta3 issue the following CQL into cqlsh:
> {code}
> drop keyspace test;
> create keyspace test with replication = {
>           'class': 'SimpleStrategy',
>           'replication_factor': '1'
>         };
> use test;
> create table users (
>             user_id text PRIMARY KEY,
>             first_name text,
>             last_name text,
>             email_addresses set<text>
>         );
> alter table users add mailing_address_lines list<text>;
> {code}
> As soon as you issue the alter table statement cqlsh hangs, and the java process hosting
Cassandra consumes 100% of a single core's CPU.
> If the alter table doesn't include a collection, it runs fine.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:

View raw message