You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Aleksey Yeschenko (JIRA)" <ji...@apache.org> on 2019/01/11 18:41:00 UTC

[jira] [Commented] (CASSANDRA-14958) Counters fail to increment in 2.1/2.2 to 3.X mixed version clusters

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

Aleksey Yeschenko commented on CASSANDRA-14958:
-----------------------------------------------

Code: [3.0|https://github.com/iamaleksey/cassandra/commits/14958-3.0], [3.11|https://github.com/iamaleksey/cassandra/commits/14958-3.11].
CI: [3.0|https://circleci.com/workflow-run/ad96e947-dff3-4d63-9c34-3e5220e550e4], [3.11|https://circleci.com/workflow-run/8378d5c3-a517-486f-8df0-b8d36c05bd79].

To fix another compatibility issue, CASSANDRA-13691 switched from using local shards to stash counter update values to a special sentinel id. {{LegacyLayout}} code was one place unfortunately not updated to reflect the change, breaking counter update cell serialisation to legacy nodes, always sending 0-increments.

The linked branches address the issue. There is no new test as this scenario is already covered pretty well by the (now working) upgrade tests.

> Counters fail to increment in 2.1/2.2 to 3.X mixed version clusters
> -------------------------------------------------------------------
>
>                 Key: CASSANDRA-14958
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-14958
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Feature/Counters
>            Reporter: Ariel Weisberg
>            Assignee: Aleksey Yeschenko
>            Priority: Critical
>             Fix For: 3.0.x, 3.11.x
>
>
> The upgrade test for this is failing
> https://circleci.com/gh/aweisberg/cassandra/2362#tests/containers/1
> I confirmed that this is occurring manually using cqlsh against the cluster constructed by the dtest.
> {noformat}
> cqlsh> describe schema;
> CREATE KEYSPACE ks WITH replication = {'class': 'SimpleStrategy', 'replication_factor': '1'}  AND durable_writes = true;
> CREATE TABLE ks.clicks (
>     userid int,
>     url text,
>     total counter,
>     PRIMARY KEY (userid, url)
> ) WITH COMPACT STORAGE
>     AND CLUSTERING ORDER BY (url 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 = {'chunk_length_in_kb': '64', 'class': 'org.apache.cassandra.io.compress.LZ4Compressor'}
>     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';
> cqlsh> use ks;
> cqlsh:ks> UPDATE clicks SET total = total + 1 WHERE userid = 1 AND url = 'http://foo.com';
> cqlsh:ks> SELECT total FROM clicks WHERE userid = 1 AND url = 'http://foo.com'
>       ... ;
>  total
> -------
>      0
> (1 rows)
> {noformat}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

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