BePPPower commented on code in PR #34422:
URL: https://github.com/apache/doris/pull/34422#discussion_r1599456341
##########
fe/fe-core/src/main/java/org/apache/doris/datasource/trinoconnector/source/TrinoConnectorScanNode.java:
##########
@@ -137,17 +151,65 @@ public List<Split> getSplits() throws UserException {
return splits;
}
+ private void applyPushDown(ConnectorSession connectorSession) {
+ // push down predicate/filter
+ Optional<ConstraintApplicationResult<ConnectorTableHandle>>
filterResult
+ = connectorMetadata.applyFilter(connectorSession,
source.getTrinoConnectorTableHandle(), constraint);
+ if (filterResult.isPresent()) {
+
source.setTrinoConnectorTableHandle(filterResult.get().getHandle());
+ }
+
+ // push down limit
+ if (hasLimit()) {
+ long limit = getLimit();
+ Optional<LimitApplicationResult<ConnectorTableHandle>> limitResult
+ = connectorMetadata.applyLimit(connectorSession,
source.getTrinoConnectorTableHandle(), limit);
+ if (limitResult.isPresent()) {
+
source.setTrinoConnectorTableHandle(limitResult.get().getHandle());
Review Comment:
This is not an issue because the content in ConnectorTableHandle has been
incremented.
--
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]