kasakrisz commented on code in PR #4864:
URL: https://github.com/apache/hive/pull/4864#discussion_r1395401671


##########
ql/src/java/org/apache/hadoop/hive/ql/exec/OperatorUtils.java:
##########
@@ -176,6 +176,37 @@ public static <T> Set<T> 
findOperatorsUpstreamJoinAccounted(Operator<?> start, C
     return found;
   }
 
+  /**
+   * Check whether there are more operators in the specified operator tree 
branch than the given limit
+   * @param start root of the operator tree to check
+   * @param opClazz type of operator to track
+   * @param limit maximum allowed number of operator in a branch of the tree
+   * @return true of limit is exceeded false otherwise
+   * @param <T> type of operator to track
+   */
+  public static <T> boolean hasMoreOperatorsThan(Operator<?> start, Class<T> 
opClazz, int limit) {
+    int count = limit;
+    if (count <= 0) {

Review Comment:
   No, I reconsidered this it should return false. 
   Fixed.



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to