gortiz commented on code in PR #10371:
URL: https://github.com/apache/pinot/pull/10371#discussion_r1124132062


##########
pinot-core/src/main/java/org/apache/pinot/core/operator/filter/FilterOperatorUtils.java:
##########
@@ -28,9 +28,207 @@
 
 
 public class FilterOperatorUtils {
+
+  private static volatile Implementation _instance = new Implementation();
+
   private FilterOperatorUtils() {
   }
 
+  public static void setImplementation(Implementation newImplementation) {
+    _instance = newImplementation;
+  }
+
+  public static class Implementation {

Review Comment:
   I would love to do that, but... how would we consume the interface from 
other classes? Right now we call the a static method, so we don't need any 
reference. If we use an interface here, we would need to supply the instance to 
all callers (like `FilterPlanNode`).
   
   Do you have an idea on how to do that without adding a new argument in the 
constructor? As said in other PRs, this is not a new problem. We may need to 
start thinking about introducing a dependency injection system like Guice in 
Pinot, as it would be less aggressive in the code than adding so many changes 
on the constructors.



-- 
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: commits-unsubscr...@pinot.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org

Reply via email to