[
https://issues.apache.org/jira/browse/HIVE-23406?focusedWorklogId=478282&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-478282
]
ASF GitHub Bot logged work on HIVE-23406:
-----------------------------------------
Author: ASF GitHub Bot
Created on: 03/Sep/20 06:05
Start Date: 03/Sep/20 06:05
Worklog Time Spent: 10m
Work Description: kasakrisz opened a new pull request #1464:
URL: https://github.com/apache/hive/pull/1464
### What changes were proposed in this pull request?
SharedWorkOptimizer compares ReduceSinkOperators by comparing the operators'
configs in ReduceSinkDesc but it doesn't check null sort order.
### Why are the changes needed?
ReduceSinkOperators are considered to be equal if both operators has a
ReduceSinkDesc object holding the same configuration. However null sort order
was not checked during similarity check.
### Does this PR introduce _any_ user-facing change?
No.
### How was this patch tested?
Run SharedWorkOptimizer q tests.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
Issue Time Tracking
-------------------
Worklog Id: (was: 478282)
Remaining Estimate: 0h
Time Spent: 10m
> SharedWorkOptimizer should check nullSortOrders when comparing ReduceSink
> operators
> -----------------------------------------------------------------------------------
>
> Key: HIVE-23406
> URL: https://issues.apache.org/jira/browse/HIVE-23406
> Project: Hive
> Issue Type: Bug
> Components: Physical Optimizer
> Reporter: Krisztian Kasa
> Assignee: Krisztian Kasa
> Priority: Major
> Time Spent: 10m
> Remaining Estimate: 0h
>
> SharedWorkOptimizer does not checks null sort order in ReduceSinkDesc when
> compares ReduceSink operators:
>
> [https://github.com/apache/hive/blob/ca9aba606c4d09b91ee28bf9ee1ae918db8cdfb9/ql/src/java/org/apache/hadoop/hive/ql/optimizer/SharedWorkOptimizer.java#L1444]
> {code:java}
> ReduceSinkDesc op1Conf = ((ReduceSinkOperator) op1).getConf();
> ReduceSinkDesc op2Conf = ((ReduceSinkOperator) op2).getConf();
> if (StringUtils.equals(op1Conf.getKeyColString(),
> op2Conf.getKeyColString()) &&
> StringUtils.equals(op1Conf.getValueColsString(),
> op2Conf.getValueColsString()) &&
> StringUtils.equals(op1Conf.getParitionColsString(),
> op2Conf.getParitionColsString()) &&
> op1Conf.getTag() == op2Conf.getTag() &&
> StringUtils.equals(op1Conf.getOrder(), op2Conf.getOrder()) &&
> op1Conf.getTopN() == op2Conf.getTopN() &&
> canDeduplicateReduceTraits(op1Conf, op2Conf)) {
> return true;
> } else {
> return false;
> }
> {code}
> An expression like
> {code:java}
> StringUtils.equals(op1Conf.getNullOrder(), op2Conf.getNullOrder()) &&
> {code}
> should be added.
>
--
This message was sent by Atlassian Jira
(v8.3.4#803005)