Jackie-Jiang commented on a change in pull request #8341:
URL: https://github.com/apache/pinot/pull/8341#discussion_r825375678



##########
File path: 
pinot-common/src/main/java/org/apache/pinot/sql/parsers/CalciteSqlParser.java
##########
@@ -757,6 +757,23 @@ private static Expression 
compileFunctionExpression(SqlBasicCall functionNode) {
     }
   }
 
+  private static final Map<String, FilterKind> 
CANONICAL_NAME_TO_FILTER_KIND_MAP = new HashMap<String, FilterKind>() {{
+    for (FilterKind filterKind : FilterKind.values()) {
+      put(StringUtils.remove(filterKind.name(), '_'), filterKind);
+    }
+  }};

Review comment:
       Good point, didn't know that.
   Here is an article explaining why this is an anti-pattern: 
https://blog.jooq.org/dont-be-clever-the-double-curly-braces-anti-pattern




-- 
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]

Reply via email to