You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Kanthi Subramanian (Jira)" <ji...@apache.org> on 2021/10/23 22:43:00 UTC

[jira] [Comment Edited] (CASSANDRA-16751) Static column added in compact tables through Cassandra-stress tool

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

Kanthi Subramanian edited comment on CASSANDRA-16751 at 10/23/21, 10:42 PM:
----------------------------------------------------------------------------

[~brandon.williams] ,Maybe this was fixed recently, counter1 table does not have static columns. And when the command is COUNTER_ADD , the counter table does have records.

select count from counter1;

count
 -------
 800

describe table counter1;

CREATE TABLE keyspace1.counter1 (
 key blob PRIMARY KEY,
 *"C0" counter,*
 *"C1" counter,*
 *"C2" counter,*
 *"C3" counter,*
 *"C4" counter*
 *) WITH additiona*l_write_policy = '99p'
 AND bloom_filter_fp_chance = 0.01
 AND caching = \{'keys': 'ALL', 'rows_per_partition': 'NONE'}
 AND cdc = false
 AND comment = ''
 AND compaction = \{'class': 'org.apache.cassandra.db.compaction.SizeTieredCompactionStrategy', 'max_threshold': '32', 'min_threshold': '4'}
 AND compression = \{'enabled': 'false'}
 AND crc_check_chance = 1.0
 AND default_time_to_live = 0
 AND extensions = {}
 AND gc_grace_seconds = 864000
 AND max_index_interval = 2048
 AND memtable_flush_period_in_ms = 0
 AND min_index_interval = 128
 AND read_repair = 'BLOCKING'
 AND speculative_retry = '99p';


was (Author: subkanthi):
Maybe this was fixed recently, counter1 table does not have static columns. And when the command is COUNTER_ADD , the counter table does have records.

select count(*) from counter1;

count
-------
 800

describe table counter1;

CREATE TABLE keyspace1.counter1 (
 key blob PRIMARY KEY,
 *"C0" counter,*
 *"C1" counter,*
 *"C2" counter,*
 *"C3" counter,*
 *"C4" counter*
 *) WITH additiona*l_write_policy = '99p'
 AND bloom_filter_fp_chance = 0.01
 AND caching = \{'keys': 'ALL', 'rows_per_partition': 'NONE'}
 AND cdc = false
 AND comment = ''
 AND compaction = \{'class': 'org.apache.cassandra.db.compaction.SizeTieredCompactionStrategy', 'max_threshold': '32', 'min_threshold': '4'}
 AND compression = \{'enabled': 'false'}
 AND crc_check_chance = 1.0
 AND default_time_to_live = 0
 AND extensions = {}
 AND gc_grace_seconds = 864000
 AND max_index_interval = 2048
 AND memtable_flush_period_in_ms = 0
 AND min_index_interval = 128
 AND read_repair = 'BLOCKING'
 AND speculative_retry = '99p';

> Static column added in compact tables through Cassandra-stress tool
> -------------------------------------------------------------------
>
>                 Key: CASSANDRA-16751
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-16751
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Tool/stress
>            Reporter: Radha
>            Assignee: Kanthi Subramanian
>            Priority: Normal
>
> I have Cassandra 3.11.9 installed on my setup. I used the Cassandra-stress
> tool to create data for my cluster.
> # cassandra-stress write n=800 -log file=/tmp/1 level=verbose -mode native
> cql3 user=cassandra password=cassandra -node nodeip
> I saw that two tables were created "counter1 and standard1".
> The "counter1" table had no data and also was created with the following
> configuration:
> cassandra@cqlsh> desc table keyspace1.counter1;
> cassandra@cqlsh> CREATE TABLE keyspace1.counter1 (
>  key blob,
>  column1 text,
>  *"C0" counter static,*
>  *"C1" counter static,*
>  *"C2" counter static,*
>  *"C3" counter static,*
>  *"C4" counter static,*
>  value counter,
>  PRIMARY KEY (key, column1)
> ) *WITH COMPACT STORAGE*
>  AND CLUSTERING ORDER BY (column1 ASC)
>  AND bloom_filter_fp_chance = 0.01
>  AND caching = \{'keys': 'ALL', 'rows_per_partition': 'NONE'}
>  AND comment = ''
>  AND compaction = {'class':
> 'org.apache.cassandra.db.compaction.SizeTieredCompactionStrategy',
> 'max_threshold': '32', 'min_threshold': '4'}
>  AND compression = \{'enabled': 'false'}
>  AND crc_check_chance = 1.0
>  AND dclocal_read_repair_chance = 0.1
>  AND default_time_to_live = 0
>  AND gc_grace_seconds = 864000
>  AND max_index_interval = 2048
>  AND memtable_flush_period_in_ms = 0
>  AND min_index_interval = 128
>  AND read_repair_chance = 0.0
>  AND speculative_retry = '99PERCENTILE';
> Now if I try to create a similar schema manually with above-mentioned
> schema, I get the following error. InvalidRequest: Error from server:
> code=2200 [Invalid query] message="Static columns are not supported in
> COMPACT STORAGE tables"
>  
> I further read more about this error and found that static columns cannot
> be used with COMPACT STORAGE tables.
> Here is the documentation for the same :
> 1. https://docs.datastax.com/en/cql-oss/3.3/cql/cql_using/useCompactStorage.html
>  2. https://programmersought.com/article/81431553936/
>  
> I raised the same on dev as well as user Cassandra forum. I have got a reply from Benjamin Lerer that this is a bug and hence raising the JIRA.
> *Query details:*
> https://lists.apache.org/thread.html/rf9c74e8e3d431ff395f73677a616a9fcd70a46f3ea0500b71ca4d91d%40%3Cdev.cassandra.apache.org%3E



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cassandra.apache.org
For additional commands, e-mail: commits-help@cassandra.apache.org