gianm commented on code in PR #19228:
URL: https://github.com/apache/druid/pull/19228#discussion_r3005401023
##########
processing/src/main/java/org/apache/druid/query/DataSource.java:
##########
@@ -105,6 +106,19 @@ public interface DataSource extends Cacheable
*/
SegmentMapFunction createSegmentMapFunction(Query query);
+ /**
+ * Returns a {@link SegmentPruner} if this datasource embeds in any
information which can be used to determine if a
+ * segment needs processed or not. Note that callers of this method will
always only be processing segments for the
+ * datasource, so there is no need for a 'default' pruner that ensures the
segment has the proper datasource. A return
+ * value of null indicates that no pruning can be performed from this
datasource, though other sources of pruning,
+ * such as filters may still be used.
+ */
+ @Nullable
+ default SegmentPruner createSegmentPruner()
Review Comment:
Could also implement this in `FilteredDataSource`.
--
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]