cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tyler Hobbs (JIRA)" <j...@apache.org>
Subject [jira] [Created] (CASSANDRA-7569) IndexOutOfBoundsException when building SyntaxError message snippet
Date Fri, 18 Jul 2014 02:39:05 GMT
Tyler Hobbs created CASSANDRA-7569:
--------------------------------------

             Summary: IndexOutOfBoundsException when building SyntaxError message snippet
                 Key: CASSANDRA-7569
                 URL: https://issues.apache.org/jira/browse/CASSANDRA-7569
             Project: Cassandra
          Issue Type: Bug
          Components: Core
            Reporter: Tyler Hobbs
            Assignee: Benjamin Lerer
            Priority: Minor
             Fix For: 2.1.1


When parsing the following query (which is expected to fail), an IndexOutOfBoundsException
is hit when looking up the bad token:

{noformat}
CREATE TABLE mytable (k int PRIMARY KEY,  v_1 tuple<int>,  v_2 tuple<int, int>,
 v_3 tuple<int, int, int>,  v_384 tuple<int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int,
int, int, int, int, int, int, int, int, int, int, int, int, int, int, int>))
{noformat}

Here's the stacktrace (after I added a log statement, which we should probably make permanent
at DEBUG level):

{noformat}
ERROR [SharedPool-Worker-3] 2014-07-17 21:30:58,165 QueryProcessor.java:465 - Exception parsing
statement:
java.lang.IndexOutOfBoundsException: Index: 1206, Size: 1206
    at java.util.ArrayList.rangeCheck(ArrayList.java:635) ~[na:1.7.0_45]
    at java.util.ArrayList.get(ArrayList.java:411) ~[na:1.7.0_45]
    at org.antlr.runtime.CommonTokenStream.get(CommonTokenStream.java:296) ~[antlr-3.2.jar:na]
    at org.apache.cassandra.cql3.ErrorCollector.appendQuerySnippet(ErrorCollector.java:118)
~[main/:na]
    at org.apache.cassandra.cql3.ErrorCollector.syntaxError(ErrorCollector.java:79) ~[main/:na]
    at org.apache.cassandra.cql3.CqlParser.displayRecognitionError(CqlParser.java:266) ~[main/:na]
    at org.antlr.runtime.BaseRecognizer.reportError(BaseRecognizer.java:186) ~[antlr-3.2.jar:na]
    at org.antlr.runtime.BaseRecognizer.recoverFromMismatchedToken(BaseRecognizer.java:596)
~[antlr-3.2.jar:na]
    at org.antlr.runtime.BaseRecognizer.match(BaseRecognizer.java:115) ~[antlr-3.2.jar:na]
    at org.apache.cassandra.cql3.CqlParser.query(CqlParser.java:367) ~[main/:na]
    at org.apache.cassandra.cql3.QueryProcessor.parseStatement(QueryProcessor.java:455) [main/:na]
    at org.apache.cassandra.cql3.QueryProcessor.getStatement(QueryProcessor.java:430) [main/:na]
    at org.apache.cassandra.cql3.QueryProcessor.process(QueryProcessor.java:200) [main/:na]
    at org.apache.cassandra.transport.messages.QueryMessage.execute(QueryMessage.java:118)
[main/:na]
    at org.apache.cassandra.transport.Message$Dispatcher.channelRead0(Message.java:421) [main/:na]
    at org.apache.cassandra.transport.Message$Dispatcher.channelRead0(Message.java:318) [main/:na]
    at io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:103)
[netty-all-4.0.20.Final.jar:4.0.20.Final]
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:332)
[netty-all-4.0.20.Final.jar:4.0.20.Final]
    at io.netty.channel.AbstractChannelHandlerContext.access$700(AbstractChannelHandlerContext.java:31)
[netty-all-4.0.20.Final.jar:4.0.20.Final]
    at io.netty.channel.AbstractChannelHandlerContext$8.run(AbstractChannelHandlerContext.java:323)
[netty-all-4.0.20.Final.jar:4.0.20.Final]
    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) [na:1.7.0_45]
    at org.apache.cassandra.concurrent.AbstractTracingAwareExecutorService$FutureTask.run(AbstractTracingAwareExecutorService.java:162)
[main/:na]
    at org.apache.cassandra.concurrent.SEPWorker.run(SEPWorker.java:103) [main/:na]
    at java.lang.Thread.run(Thread.java:744) [na:1.7.0_45]
{noformat}



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Mime
View raw message