You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@drill.apache.org by "Chun Chang (JIRA)" <ji...@apache.org> on 2014/06/09 23:41:02 UTC
[jira] [Comment Edited] (DRILL-568) set NO_EXCHANGES=true did not
have any effect
[ https://issues.apache.org/jira/browse/DRILL-568?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14025788#comment-14025788 ]
Chun Chang edited comment on DRILL-568 at 6/9/14 9:40 PM:
----------------------------------------------------------
Yes, it has been fixed.
0: jdbc:drill:schema=dfs> select name, kind, type, bool_val from sys.options where name like 'planner%';
+------------+------------+------------+------------+
| name | kind | type | bool_val |
+------------+------------+------------+------------+
| planner.enable_streamagg | BOOLEAN | SYSTEM | true |
| planner.enable_broadcast_join | BOOLEAN | SYSTEM | true |
| planner.enable_hashagg | BOOLEAN | SYSTEM | true |
| planner.disable_exchanges | BOOLEAN | SYSTEM | false |
| planner.disable_exchanges | BOOLEAN | SESSION | true |
+------------+------------+------------+------------+
}, {
"pop" : "hash-aggregate",
"@id" : 1,
"child" : 2,
"cardinality" : 1.0,
"initialAllocation" : 1000000,
"maxAllocation" : 10000000000,
"groupByExprs" : [ {
"ref" : "`c0`",
"expr" : "`c0`"
} ],
"aggrExprs" : [ ],
"htConfig" : {
"initialCapacity" : 256,
"loadFactor" : 0.75,
"keyExprsBuild" : [ {
"ref" : "`c0`",
"expr" : "`c0`"
} ],
"keyExprsProbe" : null
}
}, {
turn it to false:
0: jdbc:drill:schema=dfs> alter session set `planner.disable_exchanges` = false;
+------------+------------+
| ok | summary |
+------------+------------+
| true | planner.disable_exchanges updated. |
+------------+------------+
1 row selected (0.032 seconds)
0: jdbc:drill:schema=dfs> select name, kind, type, bool_val from sys.options where name like 'planner%';
+------------+------------+------------+------------+
| name | kind | type | bool_val |
+------------+------------+------------+------------+
| planner.enable_streamagg | BOOLEAN | SYSTEM | true |
| planner.enable_broadcast_join | BOOLEAN | SYSTEM | true |
| planner.enable_hashagg | BOOLEAN | SYSTEM | true |
| planner.disable_exchanges | BOOLEAN | SYSTEM | false |
| planner.disable_exchanges | BOOLEAN | SESSION | false |
+------------+------------+------------+------------+
5 rows selected (0.165 seconds)
0: jdbc:drill:schema=dfs> explain plan for select cast(customer.country as varchar(20)) as c0 from customer as customer where UPPER(cast(customer.country as varchar(20))) = UPPER('USA') group by cast(customer.country as varchar(20));
}, {
"pop" : "hash-to-random-exchange",
"@id" : 65538,
"child" : 131073,
"expr" : "hash(`c0`) ",
"initialAllocation" : 1000000,
"maxAllocation" : 10000000000
}, {
was (Author: cchang@maprtech.com):
0: jdbc:drill:schema=dfs> select name, kind, type, bool_val from sys.options where name like 'planner%';
+------------+------------+------------+------------+
| name | kind | type | bool_val |
+------------+------------+------------+------------+
| planner.enable_streamagg | BOOLEAN | SYSTEM | true |
| planner.enable_broadcast_join | BOOLEAN | SYSTEM | true |
| planner.enable_hashagg | BOOLEAN | SYSTEM | true |
| planner.disable_exchanges | BOOLEAN | SYSTEM | false |
| planner.disable_exchanges | BOOLEAN | SESSION | true |
+------------+------------+------------+------------+
}, {
"pop" : "hash-aggregate",
"@id" : 1,
"child" : 2,
"cardinality" : 1.0,
"initialAllocation" : 1000000,
"maxAllocation" : 10000000000,
"groupByExprs" : [ {
"ref" : "`c0`",
"expr" : "`c0`"
} ],
"aggrExprs" : [ ],
"htConfig" : {
"initialCapacity" : 256,
"loadFactor" : 0.75,
"keyExprsBuild" : [ {
"ref" : "`c0`",
"expr" : "`c0`"
} ],
"keyExprsProbe" : null
}
}, {
turn it to false:
0: jdbc:drill:schema=dfs> alter session set `planner.disable_exchanges` = false;
+------------+------------+
| ok | summary |
+------------+------------+
| true | planner.disable_exchanges updated. |
+------------+------------+
1 row selected (0.032 seconds)
0: jdbc:drill:schema=dfs> select name, kind, type, bool_val from sys.options where name like 'planner%';
+------------+------------+------------+------------+
| name | kind | type | bool_val |
+------------+------------+------------+------------+
| planner.enable_streamagg | BOOLEAN | SYSTEM | true |
| planner.enable_broadcast_join | BOOLEAN | SYSTEM | true |
| planner.enable_hashagg | BOOLEAN | SYSTEM | true |
| planner.disable_exchanges | BOOLEAN | SYSTEM | false |
| planner.disable_exchanges | BOOLEAN | SESSION | false |
+------------+------------+------------+------------+
5 rows selected (0.165 seconds)
0: jdbc:drill:schema=dfs> explain plan for select cast(customer.country as varchar(20)) as c0 from customer as customer where UPPER(cast(customer.country as varchar(20))) = UPPER('USA') group by cast(customer.country as varchar(20));
}, {
"pop" : "hash-to-random-exchange",
"@id" : 65538,
"child" : 131073,
"expr" : "hash(`c0`) ",
"initialAllocation" : 1000000,
"maxAllocation" : 10000000000
}, {
> set NO_EXCHANGES=true did not have any effect
> ---------------------------------------------
>
> Key: DRILL-568
> URL: https://issues.apache.org/jira/browse/DRILL-568
> Project: Apache Drill
> Issue Type: Bug
> Reporter: Chun Chang
>
> 0: jdbc:drill:schema=dfs> alter session set NO_EXCHANGES=true;
> +------------+------------+
> | ok | summary |
> +------------+------------+
> | true | disabled exchanges. |
> +------------+------------+
> 1 row selected (0.016 seconds)
> The explain plan for still shows we hash to random exchange:
> 0: jdbc:drill:schema=dfs> explain plan for select cast(customer.country as varchar(20)) as c0 from customer as customer where UPPER(cast(customer.country as varchar(20))) = UPPER('USA') group by cast(customer.country as varchar(20));
> +------------+------------+
> | text | json |
> +------------+------------+
> ....
> }, {
> "pop" : "hash-to-random-exchange",
> "@id" : 5,
> "child" : 4,
> "expr" : "hash(`c0`) "
> }, {
--
This message was sent by Atlassian JIRA
(v6.2#6252)