[
https://issues.apache.org/jira/browse/CASSANDRA-11177?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Philip Thompson updated CASSANDRA-11177:
----------------------------------------
Labels: cqlsh (was: )
> CQLSH causes slowdown when creating table using multiline statement
> -------------------------------------------------------------------
>
> Key: CASSANDRA-11177
> URL: https://issues.apache.org/jira/browse/CASSANDRA-11177
> Project: Cassandra
> Issue Type: Bug
> Components: Tools
> Environment: Centos 7, 16gb memory, 4 cores
> Reporter: Jim Wright
> Priority: Critical
> Labels: cqlsh
> Fix For: 3.x
>
> Attachments: mofaPqX.png
>
>
> I'm running a 3 node cluster, each with 4 cores and 16gb memory.
> When creating the following table (by copying and pasting into cqlsh) each
> line is pasted in one at a time, and the time between each line being pasted
> in seems to grow exponentially, especially once the counter columns were
> reached.
> CREATE TABLE stats_by_site_tracking_hourly (
> d_tally text, -- 2016-02
> d_date timestamp, -- 2016-02-01 13
> site_id int,
> is_new_member int, -- 1/0
> device text, -- desktop/tablet/mobile/unknown
> tracking_medium text,
> tracking_source text,
> tracking_campaign text,
> tracking_term text,
> accepted counter,
> adjusted_accepted counter,
> rejected counter,
> adjusted_rejected counter,
> error counter,
> impressions_positive counter,
> adjusted_impressions_positive counter,
> impressions_negative counter,
> adjusted_impressions_negative counter,
> revenue counter,
> adjusted_revenue counter,
> reversals_rejected counter,
> reversals_revenue counter,
> PRIMARY KEY ((d_tally), site_id, d_date, is_new_member, device,
> tracking_medium, tracking_source, tracking_campaign, tracking_term)
> );
> While I left the create table to run memory usage crept up to 70%, and CPU
> usage went up to 107%.
> I have attached a screenshot of what cqlsh looked like after ~20 minutes.
> I tried the query again but in 1 line (as below) and it executed instantly.
> CREATE TABLE stats_by_site_tracking_hourly ( d_tally text, d_date timestamp,
> site_id int, is_new_member int, device text, tracking_medium text,
> tracking_source text, tracking_campaign text, tracking_term text, accepted
> counter, adjusted_accepted counter, rejected counter, adjusted_rejected
> counter, error counter, impressions_positive counter,
> adjusted_impressions_positive counter, impressions_negative counter,
> adjusted_impressions_negative counter, revenue counter, adjusted_revenue
> counter, reversals_rejected counter, reversals_revenue counter, PRIMARY KEY
> ((d_tally), site_id, d_date, is_new_member, device, tracking_medium,
> tracking_source, tracking_campaign, tracking_term) );
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)