gianm commented on code in PR #13922:
URL: https://github.com/apache/druid/pull/13922#discussion_r1134464276
##########
processing/src/main/java/org/apache/druid/segment/UnnestStorageAdapter.java:
##########
@@ -138,13 +135,16 @@ public Sequence<Cursor> makeCursors(
retVal.getColumnSelectorFactory(),
unnestColumn,
outputColumnName,
- allowSet
+ filterPair.rhs
);
}
+ // This is needed at this moment for nested queries
+ // Future developer would want to move the virtual columns
+ // inside the UnnestCursor and wrap the columnSelectorFactory
return PostJoinCursor.wrap(
retVal,
virtualColumns,
- filterPair.rhs
+ null
Review Comment:
I would keep it happening in PostJoinCursor for a couple reasons:
1. It may never be useful to push filters into the unnest cursor, because
with `rewriteFilterOnUnnestColumnIfPossible` we are pushing them even further:
all the way to the underlying `StorageAdapter`.
2. Even if it does end up being useful to push filters into the unnest
cursor, if you aren't planning to do these optimizations immediately, it's IMO
better to keep the code simpler.
--
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]