You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Sotirios Delimanolis (JIRA)" <ji...@apache.org> on 2015/01/08 21:01:35 UTC

[jira] [Comment Edited] (CASSANDRA-8585) Thrift CLI client reporting inconsistent column family structure after upgrade to Cassandra 2.1.2

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

Sotirios Delimanolis edited comment on CASSANDRA-8585 at 1/8/15 8:01 PM:
-------------------------------------------------------------------------

Everything is a blob.

{noformat}
cqlsh:MyKeyspace> describe table "SomeColumnFamily";

CREATE TABLE "MyKeyspace"."SomeColumnFamily" (
    key blob,
    column1 blob,
    value blob,
    PRIMARY KEY (key, column1)
) WITH COMPACT STORAGE
    AND CLUSTERING ORDER BY (column1 ASC)
    AND caching = '{"keys":"ALL", "rows_per_partition":"NONE"}'
    AND comment = ''
    AND compaction = {'sstable_size_in_mb': '200', 'max_threshold': '32', 'min_threshold': '4', 'tombstone_compaction_interval': '300', 'tombstone_threshold': '0.1', 'class': 'org.apache.cassandra.db.compaction.LeveledCompactionStrategy'}
    AND compression = {'sstable_compression': 'org.apache.cassandra.io.compress.SnappyCompressor'}
    AND dclocal_read_repair_chance = 0.0
    AND default_time_to_live = 0
    AND gc_grace_seconds = 10800
    AND max_index_interval = 2048
    AND memtable_flush_period_in_ms = 0
    AND min_index_interval = 128
    AND read_repair_chance = 0.1
    AND speculative_retry = 'NONE';
{noformat}



was (Author: s_delima):
{noformat}
cqlsh:MyKeyspace> describe table "SomeColumnFamily";

CREATE TABLE "MyKeyspace"."SomeColumnFamily" (
    key blob,
    column1 blob,
    value blob,
    PRIMARY KEY (key, column1)
) WITH COMPACT STORAGE
    AND CLUSTERING ORDER BY (column1 ASC)
    AND caching = '{"keys":"ALL", "rows_per_partition":"NONE"}'
    AND comment = ''
    AND compaction = {'sstable_size_in_mb': '200', 'max_threshold': '32', 'min_threshold': '4', 'tombstone_compaction_interval': '300', 'tombstone_threshold': '0.1', 'class': 'org.apache.cassandra.db.compaction.LeveledCompactionStrategy'}
    AND compression = {'sstable_compression': 'org.apache.cassandra.io.compress.SnappyCompressor'}
    AND dclocal_read_repair_chance = 0.0
    AND default_time_to_live = 0
    AND gc_grace_seconds = 10800
    AND max_index_interval = 2048
    AND memtable_flush_period_in_ms = 0
    AND min_index_interval = 128
    AND read_repair_chance = 0.1
    AND speculative_retry = 'NONE';
{noformat}


> Thrift CLI client reporting inconsistent column family structure after upgrade to Cassandra 2.1.2
> -------------------------------------------------------------------------------------------------
>
>                 Key: CASSANDRA-8585
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-8585
>             Project: Cassandra
>          Issue Type: Bug
>          Components: API
>            Reporter: Sotirios Delimanolis
>            Priority: Minor
>             Fix For: 2.1.3
>
>
> After upgrading from Cassandra 2.0.6.4 to Cassandra 2.1.2-SNAPSHOT, the Thrift CLI client started reporting wrong default_validation_class for a Column Family.
> For example, 
> {noformat}
> [default@MyKeyspace] show schema;
> [...]
> create column family SomeColumnFamily
>   with column_type = 'Standard'
>   and comparator = 'BytesType'
>   and default_validation_class = 'BytesType'
>   and key_validation_class = 'BytesType'
>   and read_repair_chance = 0.1
>   and dclocal_read_repair_chance = 0.0
>   and gc_grace = 10800
>   and min_compaction_threshold = 4
>   and max_compaction_threshold = 32
>   and compaction_strategy = 'org.apache.cassandra.db.compaction.LeveledCompactionStrategy'
>   and caching = 'KEYS_ONLY'
>   and cells_per_row_to_cache = '0'
>   and default_time_to_live = 0
>   and speculative_retry = 'NONE'
>   and compaction_strategy_options = {'tombstone_compaction_interval' : '300', 'sstable_size_in_mb' : '200', 'tombstone_threshold' : '0.1'}
>   and compression_options = {'sstable_compression' : 'org.apache.cassandra.io.compress.SnappyCompressor'};
> {noformat}
> but
> {noformat}
> [default@MyKeyspace] describe SomeColumnFamily;
> WARNING: CQL3 tables are intentionally omitted from 'describe' output.
> See https://issues.apache.org/jira/browse/CASSANDRA-4377 for details.
>     ColumnFamily: SomeColumnFamily
>       Key Validation Class: org.apache.cassandra.db.marshal.BytesType
>       Default column value validator: org.apache.cassandra.db.marshal.UTF8Type
>       Cells sorted by: org.apache.cassandra.db.marshal.UTF8Type
>       GC grace seconds: 10800
>       Compaction min/max thresholds: 4/32
>       Read repair chance: 0.1
>       DC Local Read repair chance: 0.0
>       Caching: KEYS_ONLY
>       Default time to live: 0
>       Bloom Filter FP chance: default
>       Index interval: default
>       Speculative Retry: NONE
>       Built indexes: []
>       Compaction Strategy: org.apache.cassandra.db.compaction.LeveledCompactionStrategy
>       Compaction Strategy Options:
>         tombstone_compaction_interval: 300
>         sstable_size_in_mb: 200
>         tombstone_threshold: 0.1
>       Compression Options:
>         sstable_compression: org.apache.cassandra.io.compress.SnappyCompressor
> {noformat}
> Note how the default column value validator and cell sorting is UTF8Type rather than the BytesType reported earlier.
> If I populate the column family and list its rows, I get
> {noformat}
> [default@MyKeyspace] list SomeColumnFamily;
> Using default limit of 100
> Using default cell limit of 100
> -------------------
> RowKey: SomeRowKey
> String didn't validate.
> {noformat}
> I can't see the row. I can temporarily fix this by setting the default_column_validator
> {noformat}
> [default@MyKeyspace] update column family SomeColumnFamily with default_validation_class = BytesType;
> 0fba13e4-aac6-3963-ad65-ba354d99ebdc
> [default@MyKeyspace] list SomeColumnFamily;
> Using default limit of 100
> Using default cell limit of 100
> -------------------
> RowKey: SomeRowKey
> => (name=some name, value=some value, timestamp=635540144263687300)
> -------------------
> [More RowKeys]
> {noformat}
> If I do a DESCRIBE again, though, LIST stops working again.
> {noformat}
> [default@KeySpace] describe SomeColumnFamily;
> WARNING: CQL3 tables are intentionally omitted from 'describe' output.
> See https://issues.apache.org/jira/browse/CASSANDRA-4377 for details.
>     ColumnFamily: SomeColumnFamily
>       Key Validation Class: org.apache.cassandra.db.marshal.BytesType
>       Default column value validator: org.apache.cassandra.db.marshal.UTF8Type
>       Cells sorted by: org.apache.cassandra.db.marshal.UTF8Type
>       GC grace seconds: 10800
>       Compaction min/max thresholds: 4/32
>       Read repair chance: 0.1
>       DC Local Read repair chance: 0.0
>       Caching: KEYS_ONLY
>       Default time to live: 0
>       Bloom Filter FP chance: default
>       Index interval: default
>       Speculative Retry: NONE
>       Built indexes: []
>       Compaction Strategy: org.apache.cassandra.db.compaction.LeveledCompactionStrategy
>       Compaction Strategy Options:
>         tombstone_compaction_interval: 300
>         sstable_size_in_mb: 200
>         tombstone_threshold: 0.1
>       Compression Options:
>         sstable_compression: org.apache.cassandra.io.compress.SnappyCompressor
> [default@MyKeyspace] list SomeColumnFamily;
> Using default limit of 100
> Using default cell limit of 100
> -------------------
> RowKey: SomeRowKey
> String didn't validate.
> {noformat}
> I can access the column family rows with other clients, the C# driver for example.



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