leventov commented on a change in pull request #8209: add mechanism to control
filter optimization in historical query processing
URL: https://github.com/apache/incubator-druid/pull/8209#discussion_r311670029
##########
File path:
processing/src/main/java/org/apache/druid/query/filter/DimFilter.java
##########
@@ -82,4 +83,69 @@
* @return a HashSet that represents all columns' name which the DimFilter
required to do filter.
*/
Set<String> getRequiredColumns();
+
+ /**
+ * Wrapper for {@link StringBuilder} to re-use common patterns in custom
{@link DimFilter#toString()} implementations
+ */
+ class DimFilterToStringBuilder
+ {
+ private final StringBuilder builder;
+
+ public DimFilterToStringBuilder()
+ {
+ this.builder = new StringBuilder();
+ }
+
+ /**
+ * Append dimension name OR {@link ExtractionFn#toString()} with dimension
wrapped in parenthesis
+ */
+ DimFilterToStringBuilder appendDimension(String dimension, ExtractionFn
extractionFn)
Review comment:
`extractionFn` should be `@Nullable`
----------------------------------------------------------------
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]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]