Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
1.10.0
-
None
Description
The following query fails with IOOB when a managed sort is used, but passes with the old default sort:
=========================================
0: jdbc:drill:zk=local> alter session set `exec.sort.disable_managed` = false;
------------------------------------------+
ok | summary |
------------------------------------------+
true | exec.sort.disable_managed updated. |
------------------------------------------+
1 row selected (0.16 seconds)
0: jdbc:drill:zk=local> select * from dfs.`/data/json/s1/date_dim` where d_year in(1990, 1901, 1902, 1903, 1904, 1905, 1906, 1907, 1908, 1909, 1910, 1911, 1912, 1913, 1914, 1915, 1916, 1917, 1918, 1919) limit 3;
Error: SYSTEM ERROR: IndexOutOfBoundsException: index: 0, length: 1 (expected: range(0, 0))
Fragment 0:0
[Error Id: 370fd706-c365-421f-b57d-d6ab7fde82df on 10.250.56.251:31010] (state=,code=0)
================================================
(the above query was extracted from /root/drillAutomation/framework-master/framework/resources/Functional/tpcds/variants/hive/q4_1.sql )
Note that the inlist must have at least 20 items, in which case the plan becomes a join over a stream-aggregate over a sort over the (inlist's) values. When the IOOB happens, the stack does not show the sort anymore, but probably handling a NONE returned by the last next() on the sort ( StreamingAggTemplate.doWork():182 )
The "date_dim" can probably be made up with any data. The one above was taken from:
[root@atsqa6c85 ~]# hadoop fs -ls /drill/testdata/tpcds/json/s1/date_dim
Found 1 items
-rwxr-xr-x 3 root root 50713534 2014-10-14 22:39 /drill/testdata/tpcds/json/s1/date_dim/0_0_0.json
Attachments
Issue Links
- Is contained by
-
DRILL-5601 Rollup of External Sort memory management fixes
- Resolved