kgyrtkirk commented on code in PR #17354:
URL: https://github.com/apache/druid/pull/17354#discussion_r1824273908
##########
server/src/main/java/org/apache/druid/server/ClientQuerySegmentWalker.java:
##########
@@ -289,17 +303,15 @@ public <T> QueryRunner<T> getQueryRunnerForSegments(final
Query<T> query, final
*/
private <T> boolean canRunQueryUsingLocalWalker(Query<T> query)
{
- final DataSource dataSourceFromQuery = query.getDataSource();
- final DataSourceAnalysis analysis = dataSourceFromQuery.getAnalysis();
- final QueryToolChest<T, Query<T>> toolChest =
warehouse.getToolChest(query);
+ final DataSourceAnalysis analysis = query.getDataSourceAnalysis();
+ final QueryToolChest<T, Query<T>> toolChest =
conglomerate.getToolChest(query);
// 1) Must be based on a concrete datasource that is not a table.
// 2) Must be based on globally available data (so we have a copy here on
the Broker).
// 3) If there is an outer query, it must be handleable by the query
toolchest (the local walker does not handle
// subqueries on its own).
- return analysis.isConcreteBased() && !analysis.isConcreteAndTableBased()
&& dataSourceFromQuery.isGlobal()
- && (!(dataSourceFromQuery instanceof QueryDataSource)
- || toolChest.canPerformSubquery(((QueryDataSource)
dataSourceFromQuery).getQuery()));
+ return analysis.isConcreteBased() && !analysis.isConcreteAndTableBased()
&& analysis.isGlobal()
+ && toolChest.canExecuteFully(query);
Review Comment:
the old logic here was a bit convoluted - it was cleaned up a bit and
`canExecuteFully` was part of that cleanup; it got more readable - as of now
these lines are not anymore processed for `QueryLogic` cases
--
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]