amrishlal commented on a change in pull request #6811:
URL: https://github.com/apache/incubator-pinot/pull/6811#discussion_r619899441
##########
File path:
pinot-broker/src/main/java/org/apache/pinot/broker/requesthandler/BaseBrokerRequestHandler.java
##########
@@ -428,6 +437,38 @@ public BrokerResponse handleRequest(JsonNode request,
@Nullable RequesterIdentit
_brokerMetrics.addMeteredTableValue(rawTableName,
BrokerMeter.BROKER_RESPONSES_WITH_NUM_GROUPS_LIMIT_REACHED, 1);
}
+ logBrokerResponse(requestStatistics, requestId, query,
compilationStartTimeNs, brokerRequest,
+ numUnavailableSegments, serverStats, brokerResponse,
executionEndTimeNs);
+ return brokerResponse;
+ }
+
+ /**
+ * Given a {@link BrokerRequest}, this function will determine if we can
return a response without server-side query
+ * evaluation. This usually happens when the optimizer determines that the
entire WHERE clause evaluates to false.
+ */
+ private boolean isResponsePossible(BrokerRequest brokerRequest) {
+ if (brokerRequest == null) { return true;}
+
+ Expression filterExpression =
brokerRequest.getPinotQuery().getFilterExpression();
+ if (filterExpression != null &&
filterExpression.getType().equals(ExpressionType.LITERAL) && filterExpression
Review comment:
Reworked this a bit by using TRUE/FALSE Boolean literal constants.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]