kroeders commented on a change in pull request #10428:
URL: https://github.com/apache/druid/pull/10428#discussion_r535252310
##########
File path:
server/src/main/java/org/apache/druid/client/selector/TierSelectorStrategy.java
##########
@@ -47,6 +49,22 @@
List<QueryableDruidServer> pick(
Int2ObjectRBTreeMap<Set<QueryableDruidServer>> prioritizedServers,
DataSegment segment,
- int numServersToPick
- );
+ int numServersToPick);
+
+ @Nullable
+ default <T> QueryableDruidServer pick(Query<T> query,
+ Int2ObjectRBTreeMap<Set<QueryableDruidServer>> prioritizedServers,
+ DataSegment segment)
+ {
+ return pick(prioritizedServers, segment);
Review comment:
This was done for backward compatibility - I was trying to make this
change as minimal as possible on the first cut. We don't have any custom
implementations here and I haven't seen any on a cursory look, but I don't want
to presume. I think it's cleaner to remove the ones that don't take Query and
having an interface of all defaults that call each other makes the abstract
methods less obvious. What do you think? I'm happy to defer to your judgement.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]