Uploaded image for project: 'Apache Drill'
  1. Apache Drill
  2. DRILL-6999

Queries failed with "Failed to aggregate or route the RFW" due to "java.lang.ArrayIndexOutOfBoundsException"

    XMLWordPrintableJSON

Details

    Description

      Following query joins 2 tables on two (>1) fields.

      select count(*) from lineitem l inner join partsupp p on l.l_partkey = p.ps_partkey AND l.l_suppkey = p.ps_suppkey
      

      This is because AsyncAggregateWorker exits due to the following exception when multiple fields are used in the join condition

      2019-01-22 16:01:18,773 [drill-executor-1301] ERROR o.a.d.e.w.filter.RuntimeFilterSink - Failed to aggregate or route the RFW
      java.lang.ArrayIndexOutOfBoundsException: 1
              at org.apache.drill.exec.work.filter.RuntimeFilterWritable.unwrap(RuntimeFilterWritable.java:67) ~[drill-java-exec-1.16.0-SNAPSHOT.jar:1.16.0-SNAPSHOT]
              at org.apache.drill.exec.work.filter.RuntimeFilterWritable.aggregate(RuntimeFilterWritable.java:78) ~[drill-java-exec-1.16.0-SNAPSHOT.jar:1.16.0-SNAPSHOT]
              at org.apache.drill.exec.work.filter.RuntimeFilterSink.aggregate(RuntimeFilterSink.java:140) ~[drill-java-exec-1.16.0-SNAPSHOT.jar:1.16.0-SNAPSHOT]
              at org.apache.drill.exec.work.filter.RuntimeFilterSink.access$600(RuntimeFilterSink.java:52) ~[drill-java-exec-1.16.0-SNAPSHOT.jar:1.16.0-SNAPSHOT]
              at org.apache.drill.exec.work.filter.RuntimeFilterSink$AsyncAggregateWorker.run(RuntimeFilterSink.java:246) ~[drill-java-exec-1.16.0-SNAPSHOT.jar:1.16.0-SNAPSHOT]
              at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [na:1.8.0_151]
              at java.util.concurrent.FutureTask.run(FutureTask.java:266) [na:1.8.0_151]
              at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [na:1.8.0_151]
              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [na:1.8.0_151]
              at java.lang.Thread.run(Thread.java:748) [na:1.8.0_151]
      

      Hit the issue with latest changes in the PR -> https://github.com/apache/drill/pull/1600

      Attachments

        Issue Links

          Activity

            People

              weijie Weijie Tong
              shamirwasia Sorabh Hamirwasia
              Sorabh Hamirwasia Sorabh Hamirwasia
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: