Details
-
Bug
-
Status: Closed
-
Blocker
-
Resolution: Fixed
-
0.8.0
-
None
-
None
-
RHEL 6.4
Description
When launching concurrently queries on multiple connections (1 query per connection) for the 1st time, some queries (which otherwise run without issue) fail with IndexOutOfBoundsException
Here is a sample case where 2 threads (PipSQuawkling.java) executed 2 different queries on separate SQL Connection objects.
2015-03-25 19:07:20 [pip1] INFO PipSQuawkling executeTest - [ 0 / 03_par100 ] Executing query...
Query failed: IndexOutOfBoundsException: Index: 10, Size: 7
2015-03-25 19:07:23 [pip1] ERROR PipSQuawkling executeQuery - [ 0 / 03_par100 ] exception while executing query: Failure while executing query.
java.sql.SQLException: exception while executing query: Failure while executing query.
at net.hydromatic.avatica.Helper.createException(Helper.java:40)
at net.hydromatic.avatica.AvaticaConnection.executeQueryInternal(AvaticaConnection.java:406)
at net.hydromatic.avatica.AvaticaStatement.executeQueryInternal(AvaticaStatement.java:351)
at net.hydromatic.avatica.AvaticaStatement.executeQuery(AvaticaStatement.java:78)
at PipSQuawkling.executeQuery(PipSQuawkling.java:284)
at PipSQuawkling.executeTest(PipSQuawkling.java:144)
at PipSQuawkling.run(PipSQuawkling.java:76)
Caused by: java.sql.SQLException: Failure while executing query.
at org.apache.drill.jdbc.DrillCursor.next(DrillCursor.java:144)
at org.apache.drill.jdbc.DrillResultSet.execute(DrillResultSet.java:110)
at org.apache.drill.jdbc.DrillResultSet.execute(DrillResultSet.java:49)
at net.hydromatic.avatica.AvaticaConnection.executeQueryInternal(AvaticaConnection.java:404)
... 5 more
Caused by: org.apache.drill.exec.rpc.RpcException: IndexOutOfBoundsException: Index: 10, Size: 7
at org.apache.drill.exec.rpc.user.QueryResultHandler.batchArrived(QueryResultHandler.java:157)
at org.apache.drill.exec.rpc.user.UserClient.handleReponse(UserClient.java:93)
at org.apache.drill.exec.rpc.BasicClientWithConnection.handle(BasicClientWithConnection.java:52)
at org.apache.drill.exec.rpc.BasicClientWithConnection.handle(BasicClientWithConnection.java:34)
at org.apache.drill.exec.rpc.RpcBus.handle(RpcBus.java:57)
at org.apache.drill.exec.rpc.RpcBus$InboundHandler.decode(RpcBus.java:194)
at org.apache.drill.exec.rpc.RpcBus$InboundHandler.decode(RpcBus.java:173)
at io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:89)
at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:333)
at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:319)
at io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:103)
at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:333)
at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:319)
at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:161)
at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:333)
at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:319)
at io.netty.channel.ChannelInboundHandlerAdapter.channelRead(ChannelInboundHandlerAdapter.java:86)
at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:333)
at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:319)
at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:787)
at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:130)
at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:511)
at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:468)
at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:382)
at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:354)
at io.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:116)
at java.lang.Thread.run(Thread.java:744)
2015-03-25 19:07:23 [pip1] INFO PipSQuawkling executeQuery - [ 0 / 03_par100 ] Executed in 2369 msec
2015-03-25 19:07:23 [pip1] INFO PipSQuawkling executeTest - [ 0 / 03_par100 ] Fetching rows...
2015-03-25 19:07:23 [pip1] ERROR PipSQuawkling fetchRows - [ 0 / 03_par100 ] Skipping fetch() due to execute() failure
2015-03-25 19:07:23 [pip1] ERROR PipSQuawkling executeTest - [ 0 / 03_par100 ] Actual Query Time 2369 msec
Attachments
Attachments
Issue Links
- Is contained by
-
DRILL-2633 Visitors (PreProcessLogicalRel and UnsupportedOperatorsVisitor) are shared unsafely
- Resolved