ngsg commented on code in PR #3998:
URL: https://github.com/apache/hive/pull/3998#discussion_r1546273306


##########
ql/src/java/org/apache/hadoop/hive/ql/optimizer/SharedWorkOptimizer.java:
##########
@@ -1863,12 +1863,19 @@ private static boolean validPreConditions(ParseContext 
pctx, SharedWorkOptimizer
     }
 
     OperatorGraph og = new OperatorGraph(pctx);
-    Set<OperatorGraph.Cluster> cc1 = 
og.clusterOf(op1).childClusters(edgePredicate);
-    Set<OperatorGraph.Cluster> cc2 = 
og.clusterOf(op2).childClusters(edgePredicate);
+    Set<Cluster> clusterSet1 = og.clusterOf(op1);
+    Set<Cluster> clusterSet2 = og.clusterOf(op2);
 
-    if (!Collections.disjoint(cc1, cc2)) {
-      LOG.debug("merge would create an unsupported parallel edge(CHILDS)", 
op1, op2);
-      return false;
+    for (Cluster cluster1: clusterSet1) {
+      for (Cluster cluster2: clusterSet2) {
+        Set<Cluster> cc1 = cluster1.childClusters(edgePredicate);
+        Set<Cluster> cc2 = cluster2.childClusters(edgePredicate);
+
+        if (!Collections.disjoint(cc1, cc2)) {
+          LOG.debug("merge would create an unsupported parallel edge(CHILDS)", 
op1, op2);

Review Comment:
   Thanks for pointing that out; fixed debug messages



-- 
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.

To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org
For additional commands, e-mail: gitbox-h...@hive.apache.org

Reply via email to