cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Arron Norwell (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CASSANDRA-7867) Added column does not sort as the last column
Date Mon, 01 Jun 2015 18:02:21 GMT

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

Arron Norwell commented on CASSANDRA-7867:
------------------------------------------

I have encountered this, and it was reproducible as follows:

Environment: 21 node Cassandra 2.0.11 cluster. Client requests made using the datastax ruby
driver ( https://github.com/datastax/ruby-driver
) -- cqlsh doesn't support paging as of the version distributed with Cassandra 2.0.11.
{noformat}
CREATE TABLE test_bug_2 (
  row int,
  col int,
  PRIMARY KEY ((row), col)
) WITH
  bloom_filter_fp_chance=0.010000 AND
  caching='KEYS_ONLY' AND
  comment='' AND
  dclocal_read_repair_chance=0.100000 AND
  gc_grace_seconds=864000 AND
  index_interval=128 AND
  read_repair_chance=0.000000 AND
  replicate_on_write='true' AND
  populate_io_cache_on_flush='false' AND
  default_time_to_live=0 AND
  speculative_retry='99.0PERCENTILE' AND
  memtable_flush_period_in_ms=0 AND
  compaction={'class': 'SizeTieredCompactionStrategy'} AND
  compression={'sstable_compression': 'LZ4Compressor'};
{noformat}

Using the ruby CQL client: 
{noformat}
# Connect to the cluster and keyspace
session = Cassandra.cluster(...).connect('test_keyspace')

# Populate some test data
(0..100).each { |i| session.execute("INSERT into test_bug_2 (row, col) values (1, #{i})")

# request the first page
page = session.execute("SELECT * from test_bug_2 WHERE row = 1 ORDER BY col desc", :page_size
=> 20)

# Repeatedly request the next page
(0..100) { session.execute("SELECT * from test_bug_2 WHERE row = 1 ORDER BY col desc", :page_size
=> 20, :paging_state => page.paging_state) }
{noformat}

Each query using the SELECT statement has a small chance of failing, maybe once every 5-6
queries in my experience. This doesn't seem to happen in all environments, even using Cassandra
2.0.11 -- In a single node development cluster I have not been able to reproduce it.

The error logged on the server is as follows:

{noformat}
ERROR [Native-Transport-Requests:492804] 2015-06-01 11:41:30,120 Message.java (line 403) Unexpected
exception during request; channel = [id: 0xe2ba33b9, /172.16.1.120:62399 => /172.16.4.219:9042]
java.lang.AssertionError: Added column does not sort as the last column
at org.apache.cassandra.db.ArrayBackedSortedColumns.addColumn(ArrayBackedSortedColumns.java:115)
at org.apache.cassandra.db.ColumnFamily.addColumn(ColumnFamily.java:116)
at org.apache.cassandra.service.pager.AbstractQueryPager.discardHead(AbstractQueryPager.java:319)
at org.apache.cassandra.service.pager.AbstractQueryPager.discardLast(AbstractQueryPager.java:301)
at org.apache.cassandra.service.pager.AbstractQueryPager.discardFirst(AbstractQueryPager.java:219)
at org.apache.cassandra.service.pager.AbstractQueryPager.discardFirst(AbstractQueryPager.java:202)
at org.apache.cassandra.service.pager.AbstractQueryPager.fetchPage(AbstractQueryPager.java:124)
at org.apache.cassandra.service.pager.SliceQueryPager.fetchPage(SliceQueryPager.java:35)
at org.apache.cassandra.cql3.statements.SelectStatement.execute(SelectStatement.java:240)
at org.apache.cassandra.cql3.statements.SelectStatement.execute(SelectStatement.java:65)
at org.apache.cassandra.cql3.QueryProcessor.processStatement(QueryProcessor.java:158)
at org.apache.cassandra.cql3.QueryProcessor.processPrepared(QueryProcessor.java:309)
at org.apache.cassandra.transport.messages.ExecuteMessage.execute(ExecuteMessage.java:132)
at org.apache.cassandra.transport.Message$Dispatcher.messageReceived(Message.java:321)
at org.jboss.netty.channel.SimpleChannelUpstreamHandler.handleUpstream(SimpleChannelUpstreamHandler.java:70)
at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:564)
at org.jboss.netty.channel.DefaultChannelPipeline$DefaultChannelHandlerContext.sendUpstream(DefaultChannelPipeline.java:791)
at org.jboss.netty.handler.execution.ChannelUpstreamEventRunnable.doRun(ChannelUpstreamEventRunnable.java:43)
at org.jboss.netty.handler.execution.ChannelEventRunnable.run(ChannelEventRunnable.java:67)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:744)
{noformat}

> Added column does not sort as the last column
> ---------------------------------------------
>
>                 Key: CASSANDRA-7867
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-7867
>             Project: Cassandra
>          Issue Type: Bug
>         Environment: 6-node Cassandra 2.0.9 with r=3
> java version "1.7.0_45"
> Java(TM) SE Runtime Environment (build 1.7.0_45-b18)
> Java HotSpot(TM) 64-Bit Server VM (build 24.45-b08, mixed mode)
> Linux 3.10.40-50.136.amzn1.x86_64 #1 SMP Tue May 13 21:35:08 UTC 2014 x86_64 x86_64 x86_64
GNU/Linux
> Client is using DataStax java client v2.0.3
>            Reporter: Bob Vawter
>
> This appears to be a stack trace distinct from that in CASSANDRA-5856.
> {noformat}
> java.lang.AssertionError: Added column does not sort as the last column
>         at org.apache.cassandra.db.ArrayBackedSortedColumns.addColumn(ArrayBackedSortedColumns.java:115)
>         at org.apache.cassandra.db.ColumnFamily.addColumn(ColumnFamily.java:116)
>         at org.apache.cassandra.service.pager.AbstractQueryPager.discardHead(AbstractQueryPager.java:319)
>         at org.apache.cassandra.service.pager.AbstractQueryPager.discardLast(AbstractQueryPager.java:301)
>         at org.apache.cassandra.service.pager.AbstractQueryPager.discardFirst(AbstractQueryPager.java:219)
>         at org.apache.cassandra.service.pager.AbstractQueryPager.discardFirst(AbstractQueryPager.java:202)
>         at org.apache.cassandra.service.pager.AbstractQueryPager.fetchPage(AbstractQueryPager.java:124)
>         at org.apache.cassandra.service.pager.SliceQueryPager.fetchPage(SliceQueryPager.java:35)
>         at org.apache.cassandra.cql3.statements.SelectStatement.execute(SelectStatement.java:236)
>         at org.apache.cassandra.cql3.statements.SelectStatement.execute(SelectStatement.java:61)
>         at org.apache.cassandra.cql3.QueryProcessor.processStatement(QueryProcessor.java:158)
>         at org.apache.cassandra.cql3.QueryProcessor.process(QueryProcessor.java:175)
>         at org.apache.cassandra.transport.messages.QueryMessage.execute(QueryMessage.java:119)
>         at org.apache.cassandra.transport.Message$Dispatcher.messageReceived(Message.java:304)
>         at org.jboss.netty.handler.execution.ChannelUpstreamEventRunnable.doRun(ChannelUpstreamEventRunnable.java:43)
>         at org.jboss.netty.handler.execution.ChannelEventRunnable.run(ChannelEventRunnable.java:67)
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
>         at java.lang.Thread.run(Thread.java:744)
> {noformat}
> The underlying table is an append-only event log and is usually being queried in descending
ts order:
> {noformat}
> CREATE TABLE ledger (
>   id blob,
>   ts timeuuid,
>   data text,
>   json_key text,
>   type text,
>   PRIMARY KEY ((id), ts)
> ) WITH
>   bloom_filter_fp_chance=0.010000 AND
>   caching='KEYS_ONLY' AND
>   comment='' AND
>   dclocal_read_repair_chance=0.100000 AND
>   gc_grace_seconds=864000 AND
>   index_interval=128 AND
>   read_repair_chance=0.000000 AND
>   replicate_on_write='true' AND
>   populate_io_cache_on_flush='false' AND
>   default_time_to_live=0 AND
>   speculative_retry='99.0PERCENTILE' AND
>   memtable_flush_period_in_ms=0 AND
>   compaction={'class': 'SizeTieredCompactionStrategy'} AND
>   compression={'sstable_compression': 'LZ4Compressor'};
> {noformat}



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

Mime
View raw message