Github user paul-rogers commented on a diff in the pull request:

    https://github.com/apache/drill/pull/868#discussion_r126827426
  
    --- Diff: 
exec/java-exec/src/main/java/org/apache/drill/exec/server/options/OptionValidator.java
 ---
    @@ -106,4 +107,16 @@ public boolean isAdminOption() {
        */
       public abstract Kind getKind();
     
    +  /**
    +   * Gets the default result option value for this validator.
    +   *
    +   * @return result default option value
    +   */
    +  public abstract OptionValue loadConfigDefault(DrillConfig bootConfig, 
String name, String configPath);
    --- End diff --
    
    Passing in the config is file. Bug, shouldn't the name and config path 
already be known? The name is the config property name (in most cases) isn't 
it? The path is fixed and can be constant?
    
    I'd have thought that we'd declare validators something like this:
    
    ```
    public static FOO_VALIDATOR = new StringValidator("exec.foo");
    public static BAR_VALIDATOR = new IntValidator("exec.bar", 
"drill.non.standard.name.bar");
    ```
    Since the validator is given the name, it need not ask for it again here, 
it would seem...


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