[ 
https://issues.apache.org/jira/browse/DRILL-4596?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15232776#comment-15232776
 ] 

ASF GitHub Bot commented on DRILL-4596:
---------------------------------------

Github user arina-ielchiieva commented on a diff in the pull request:

    https://github.com/apache/drill/pull/474#discussion_r59077998
  
    --- Diff: 
exec/java-exec/src/main/java/org/apache/drill/exec/server/Drillbit.java ---
    @@ -207,6 +209,28 @@ private void javaPropertiesToSystemOptions() {
       }
     
       /**
    +   * Disallow registering drillbit when:
    +   * 1. version is unknown;
    +   * 2. drillbit with different version has been already registered.
    +   */
    +  private void checkVersion(DrillbitEndpoint endpoint) throws 
DrillbitStartupException {
    +    String currentVersion = endpoint.getVersion();
    +    if (DrillVersionInfo.UNKNOWN_VERSION.equals(currentVersion)) {
    +      throw new DrillbitStartupException("Drillbit version is unknown.");
    +    }
    +
    +    for (DrillbitEndpoint registeredEnpoint : 
coord.getAvailableEndpoints()) {
    +      if (!currentVersion.equals(registeredEnpoint.getVersion())) {
    --- End diff --
    
    Agree. Probably it's better to compare each module major versions.


> Drill should do version check among drillbits
> ---------------------------------------------
>
>                 Key: DRILL-4596
>                 URL: https://issues.apache.org/jira/browse/DRILL-4596
>             Project: Apache Drill
>          Issue Type: New Feature
>    Affects Versions: 1.6.0
>            Reporter: Arina Ielchiieva
>            Assignee: Arina Ielchiieva
>             Fix For: Future
>
>
> Before registering new drillbit in zookeeper, we should do version check, and 
> make sure all the running drillbits are in the same version.
> Using drillbits of different version can lead to unexpected results.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to