Github user hsuanyi commented on a diff in the pull request:

    https://github.com/apache/drill/pull/377#discussion_r53536850
  
    --- Diff: 
exec/java-exec/src/main/java/org/apache/drill/exec/expr/fn/DrillFunctionRegistry.java
 ---
    @@ -17,40 +17,42 @@
      */
     package org.apache.drill.exec.expr.fn;
     
    -import java.util.Arrays;
     import java.util.Collection;
    +import java.util.Collections;
     import java.util.HashMap;
    -import java.util.HashSet;
     import java.util.List;
    +import java.util.Map;
     import java.util.Map.Entry;
    -import java.util.Set;
     
    -import org.apache.calcite.sql.SqlOperator;
    +import com.google.common.collect.Lists;
     import 
org.apache.drill.common.scanner.persistence.AnnotatedClassDescriptor;
     import org.apache.drill.common.scanner.persistence.ScanResult;
    -import org.apache.drill.exec.expr.DrillFunc;
    +import 
org.apache.drill.exec.expr.annotations.FunctionTemplate.FunctionArgumentNumber;
     import org.apache.drill.exec.planner.logical.DrillConstExecutor;
     import org.apache.drill.exec.planner.sql.DrillOperatorTable;
     import org.apache.drill.exec.planner.sql.DrillSqlAggOperator;
     import org.apache.drill.exec.planner.sql.DrillSqlOperator;
     
     import com.google.common.collect.ArrayListMultimap;
    -import com.google.common.collect.Sets;
     
    +/**
    + * Registry of Drill functions.
    + */
     public class DrillFunctionRegistry {
    -  static final org.slf4j.Logger logger = 
org.slf4j.LoggerFactory.getLogger(DrillFunctionRegistry.class);
    -
    -  private ArrayListMultimap<String, DrillFuncHolder> methods = 
ArrayListMultimap.create();
    +  private static final org.slf4j.Logger logger = 
org.slf4j.LoggerFactory.getLogger(DrillFunctionRegistry.class);
     
    -  /* Hash map to prevent registering functions with exactly matching 
signatures
    -   * key: Function Name + Input's Major Type
    -   * Value: Class name where function is implemented
    -   */
    -  private HashMap<String, String> functionSignatureMap = new HashMap<>();
    --- End diff --
    
    This functionSignatureMap is moved into the body of the a method (the 
constructor), where access modified cannot be added. 


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to