gortiz commented on code in PR #13999:
URL: https://github.com/apache/pinot/pull/13999#discussion_r1771350664


##########
pinot-core/src/main/java/org/apache/pinot/core/query/executor/ServerQueryExecutorV1Impl.java:
##########
@@ -441,7 +444,15 @@ private InstanceResponseBlock 
executeInternal(TableDataManager tableDataManager,
       if (queryContext.isExplain()) {
         instanceResponse = 
getExplainResponseForNoMatchingSegment(numTotalSegments, queryContext);
       } else {
-        instanceResponse = new 
InstanceResponseBlock(ResultsBlockUtils.buildEmptyQueryResults(queryContext));
+        if (QueryContextUtils.isTimeSeriesQuery(queryContext)) {
+          // TODO: handle invalid segments
+          TimeSeriesBlock seriesBlock = new TimeSeriesBlock(
+              queryContext.getTimeSeriesContext().getTimeBuckets(), 
Collections.emptyMap());
+          TimeSeriesResultsBlock resultsBlock = new 
TimeSeriesResultsBlock(seriesBlock);
+          instanceResponse = new InstanceResponseBlock(resultsBlock);

Review Comment:
   Shouldn't this code be in `ResultsBlockUtils.buildEmptyQueryResults`?



-- 
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: commits-unsubscr...@pinot.apache.org

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


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

Reply via email to