You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@drill.apache.org by vi...@apache.org on 2018/12/24 17:27:06 UTC

[drill] branch master updated (af3977a -> 3e2d619)

This is an automated email from the ASF dual-hosted git repository.

vitalii pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/drill.git.


    from af3977a  DRILL-6919: Fix compilation error in TestGracefulShutdown class for mapr profile
     new 4a771d0  DRILL-6925: Unable to generate Protobuf
     new 44f17ea  DRILL-6922: Do not set return result set option on query level if it is the same as current value
     new 3e2d619  DRILL-6920: Fix TestClient.testBasics() yarn test failure

The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .mvn/extensions.xml                                |  2 +-
 contrib/native/client/src/protobuf/BitData.pb.cc   | 56 ++++++++++++++++++---
 contrib/native/client/src/protobuf/BitData.pb.h    | 34 ++++++++++++-
 .../org/apache/drill/yarn/client/TestClient.java   | 12 +----
 .../java/org/apache/drill/exec/ExecConstants.java  |  9 ++--
 .../drill/exec/planner/sql/DrillSqlWorker.java     | 12 +++--
 .../drill/exec/server/options/OptionValue.java     |  7 ++-
 .../exec/server/rest/profile/ProfileWrapper.java   | 33 ++++++++++---
 .../org/apache/drill/exec/ssl/SSLConfigClient.java |  4 +-
 .../org/apache/drill/exec/ssl/SSLConfigServer.java |  4 +-
 .../java-exec/src/main/resources/drill-module.conf |  2 +-
 .../src/main/resources/rest/profile/profile.ftl    | 57 +++++++++++++---------
 pom.xml                                            | 10 ++--
 .../org/apache/drill/exec/proto/UserBitShared.java | 40 +++++++++++++++
 14 files changed, 213 insertions(+), 69 deletions(-)


[drill] 02/03: DRILL-6922: Do not set return result set option on query level if it is the same as current value

Posted by vi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

vitalii pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/drill.git

commit 44f17eaf1b9489fc16fadee0178e975f6aff5185
Author: Arina Ielchiieva <ar...@gmail.com>
AuthorDate: Sun Dec 23 17:10:39 2018 +0200

    DRILL-6922: Do not set return result set option on query level if it is the same as current value
    
    1. Rename return result option name to `exec.query.return_result_set_for_ddl`.
    2. Add check if option value is the same as current value in DrillSqlWorker before setting result set option on query level.
    3. Separate Session and Query options on Web UI.
    
    closes #1584
---
 .../java/org/apache/drill/exec/ExecConstants.java  |  9 ++--
 .../drill/exec/planner/sql/DrillSqlWorker.java     | 12 +++--
 .../drill/exec/server/options/OptionValue.java     |  7 ++-
 .../exec/server/rest/profile/ProfileWrapper.java   | 33 ++++++++++---
 .../java-exec/src/main/resources/drill-module.conf |  2 +-
 .../src/main/resources/rest/profile/profile.ftl    | 57 +++++++++++++---------
 6 files changed, 78 insertions(+), 42 deletions(-)

diff --git a/exec/java-exec/src/main/java/org/apache/drill/exec/ExecConstants.java b/exec/java-exec/src/main/java/org/apache/drill/exec/ExecConstants.java
index c4d7652..afa29d9 100644
--- a/exec/java-exec/src/main/java/org/apache/drill/exec/ExecConstants.java
+++ b/exec/java-exec/src/main/java/org/apache/drill/exec/ExecConstants.java
@@ -854,7 +854,7 @@ public final class ExecConstants {
    * the shutdown request is triggered. The primary use of grace period is to
    * avoid the race conditions caused by zookeeper delay in updating the state
    * information of the drillbit that is shutting down. So, it is advisable
-   * to have a grace period that is atleast twice the amount of zookeeper
+   * to have a grace period that is at least twice the amount of zookeeper
    * refresh time.
    */
   public static final String GRACE_PERIOD = "drill.exec.grace_period_ms";
@@ -880,10 +880,11 @@ public final class ExecConstants {
 
   public static final String LIST_FILES_RECURSIVELY = "storage.list_files_recursively";
   public static final BooleanValidator LIST_FILES_RECURSIVELY_VALIDATOR = new BooleanValidator(LIST_FILES_RECURSIVELY,
-      new OptionDescription("Enables recursive files listing when querying the `INFORMATION_SCHEMA.FILES` table or executing the SHOW FILES command. Default is false. (Drill 1.15+)"));
+      new OptionDescription("Enables recursive files listing when querying the `INFORMATION_SCHEMA.FILES` table or executing the SHOW FILES command. " +
+        "Default is false. (Drill 1.15+)"));
 
-  public static final String RETURN_RESULT_SET_FOR_DDL = "exec.return_result_set_for_ddl";
+  public static final String RETURN_RESULT_SET_FOR_DDL = "exec.query.return_result_set_for_ddl";
   public static final BooleanValidator RETURN_RESULT_SET_FOR_DDL_VALIDATOR = new BooleanValidator(RETURN_RESULT_SET_FOR_DDL,
-      new OptionDescription("Controls whether to return result set for CREATE TABLE/VIEW, DROP TABLE/VIEW, SET, USE etc. queries. " +
+      new OptionDescription("Controls whether to return result set for CREATE TABLE / VIEW, DROP TABLE / VIEW, SET, USE etc. queries. " +
           "If set to false affected rows count will be returned instead and result set will be null. Default is true. (Drill 1.15+)"));
 }
diff --git a/exec/java-exec/src/main/java/org/apache/drill/exec/planner/sql/DrillSqlWorker.java b/exec/java-exec/src/main/java/org/apache/drill/exec/planner/sql/DrillSqlWorker.java
index c7963a5..c92f5f8 100644
--- a/exec/java-exec/src/main/java/org/apache/drill/exec/planner/sql/DrillSqlWorker.java
+++ b/exec/java-exec/src/main/java/org/apache/drill/exec/planner/sql/DrillSqlWorker.java
@@ -173,11 +173,13 @@ public class DrillSqlWorker {
         handler = new DefaultSqlHandler(config, textPlan);
     }
 
-    boolean returnResultSet = context.getOptions().getBoolean(ExecConstants.RETURN_RESULT_SET_FOR_DDL);
-    // Determine whether result set should be returned for the query based on `exec.return_result_set_for_ddl`
-    // and sql node kind. Overrides the option on a query level.
-    context.getOptions().setLocalOption(ExecConstants.RETURN_RESULT_SET_FOR_DDL,
-        returnResultSet || !SqlKind.DDL.contains(sqlNode.getKind()));
+    // Determines whether result set should be returned for the query based on return result set option and sql node kind.
+    // Overrides the option on a query level if it differs from the current value.
+    boolean currentReturnResultValue = context.getOptions().getBoolean(ExecConstants.RETURN_RESULT_SET_FOR_DDL);
+    boolean newReturnResultSetValue = currentReturnResultValue || !SqlKind.DDL.contains(sqlNode.getKind());
+    if (newReturnResultSetValue != currentReturnResultValue) {
+      context.getOptions().setLocalOption(ExecConstants.RETURN_RESULT_SET_FOR_DDL, true);
+    }
 
     return handler.getPlan(sqlNode);
   }
diff --git a/exec/java-exec/src/main/java/org/apache/drill/exec/server/options/OptionValue.java b/exec/java-exec/src/main/java/org/apache/drill/exec/server/options/OptionValue.java
index 3a7dcff..61d430d 100644
--- a/exec/java-exec/src/main/java/org/apache/drill/exec/server/options/OptionValue.java
+++ b/exec/java-exec/src/main/java/org/apache/drill/exec/server/options/OptionValue.java
@@ -84,7 +84,7 @@ public class OptionValue implements Comparable<OptionValue> {
    * This defines where an option was actually configured.
    */
   public enum OptionScope {
-    BOOT, SYSTEM, SESSION, QUERY;
+    BOOT, SYSTEM, SESSION, QUERY
   }
 
   public final String name;
@@ -186,6 +186,11 @@ public class OptionValue implements Comparable<OptionValue> {
     }
   }
 
+  @JsonIgnore
+  public OptionScope getScope() {
+    return scope;
+  }
+
   public PersistedOptionValue toPersisted() {
     return new PersistedOptionValue(kind, name, num_val, string_val, bool_val, float_val);
   }
diff --git a/exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/profile/ProfileWrapper.java b/exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/profile/ProfileWrapper.java
index 1faf6e4..35a3706 100644
--- a/exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/profile/ProfileWrapper.java
+++ b/exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/profile/ProfileWrapper.java
@@ -24,6 +24,9 @@ import java.util.Collections;
 import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
+import java.util.TreeMap;
+import java.util.function.Predicate;
+import java.util.stream.Collectors;
 
 import org.apache.commons.lang3.tuple.ImmutablePair;
 import org.apache.drill.common.config.DrillConfig;
@@ -40,7 +43,6 @@ import org.apache.drill.exec.server.rest.WebServer;
 
 import com.fasterxml.jackson.databind.ObjectMapper;
 import org.apache.drill.shaded.guava.com.google.common.base.CaseFormat;
-import org.apache.drill.shaded.guava.com.google.common.collect.Maps;
 
 /**
  * Wrapper class for a {@link #profile query profile}, so it to be presented through web UI.
@@ -303,22 +305,39 @@ public class ProfileWrapper {
     return sb.append("}").toString();
   }
 
+  public Map<String, String> getOptions() {
+    return getOptions(o -> true);
+  }
+
+  public Map<String, String> getSessionOptions() {
+    return getOptions(o -> OptionValue.OptionScope.SESSION == o.getScope());
+  }
+
+  public Map<String, String> getQueryOptions() {
+    return getOptions(o -> OptionValue.OptionScope.QUERY == o.getScope());
+  }
+
   /**
    * Generates sorted map with properties used to display on Web UI,
    * where key is property name and value is property string value.
+   * Options are filtered based on {@link OptionValue.OptionScope}.
+   * <p/>
    * When property value is null, it would be replaced with 'null',
    * this is achieved using {@link String#valueOf(Object)} method.
    * Options will be stored in ascending key order, sorted according
    * to the natural order for the option name represented by {@link String}.
    *
+   * @param filter filter based on {@link OptionValue.OptionScope}
    * @return map with properties names and string values
    */
-  public Map<String, String> getOptions() {
-    final Map<String, String> map = Maps.newTreeMap();
-    for (OptionValue option : options) {
-      map.put(option.getName(), String.valueOf(option.getValue()));
-    }
-    return map;
+  private Map<String, String> getOptions(Predicate<OptionValue> filter) {
+    return options.stream()
+      .filter(filter)
+      .collect(Collectors.toMap(
+        OptionValue::getName,
+        o -> String.valueOf(o.getValue()),
+        (o, n) -> n,
+        TreeMap::new));
   }
 
   /**
diff --git a/exec/java-exec/src/main/resources/drill-module.conf b/exec/java-exec/src/main/resources/drill-module.conf
index a2d3cdc..3682a85 100644
--- a/exec/java-exec/src/main/resources/drill-module.conf
+++ b/exec/java-exec/src/main/resources/drill-module.conf
@@ -646,5 +646,5 @@ drill.exec.options: {
     planner.index.prefer_intersect_plans: false,
     planner.index.max_indexes_to_intersect: 5,
     exec.query.rowkeyjoin_batchsize: 128,
-    exec.return_result_set_for_ddl: true,
+    exec.query.return_result_set_for_ddl: true
 }
diff --git a/exec/java-exec/src/main/resources/rest/profile/profile.ftl b/exec/java-exec/src/main/resources/rest/profile/profile.ftl
index 59f8485..ee126ab 100644
--- a/exec/java-exec/src/main/resources/rest/profile/profile.ftl
+++ b/exec/java-exec/src/main/resources/rest/profile/profile.ftl
@@ -288,38 +288,23 @@ table.sortable thead .sorting_desc { background-image: url("/static/img/black-de
     </div>
   </div>
 
-  <#assign options = model.getOptions()>
-  <#if (options?keys?size > 0)>
+  <#assign sessionOptions = model.getSessionOptions()>
+  <#assign queryOptions = model.getQueryOptions()>
+  <#if (sessionOptions?keys?size > 0 || queryOptions?keys?size > 0) >
     <div class="page-header"></div>
-    <h3>Session Options</h3>
-    <div class="panel-group" id="session-options-accordion">
+    <h3>Options</h3>
+    <div class="panel-group" id="options-accordion">
       <div class="panel panel-default">
         <div class="panel-heading">
           <h4 class="panel-title">
-            <a data-toggle="collapse" href="#session-options-overview">
+            <a data-toggle="collapse" href="#options-overview">
               Overview
             </a>
           </h4>
         </div>
-        <div id="session-options-overview" class="panel-collapse collapse in">
-          <div class="panel-body">
-            <table class="table table-bordered">
-              <thead>
-                <tr>
-                  <th>Name</th>
-                  <th>Value</th>
-                </tr>
-              </thead>
-              <tbody>
-                <#list options?keys as name>
-                  <tr>
-                    <td>${name}</td>
-                    <td>${options[name]}</td>
-                  </tr>
-                </#list>
-              </tbody>
-            </table>
-          </div>
+        <div id="options-overview" class="panel-collapse collapse in">
+          <@list_options options=sessionOptions scope="Session" />
+          <@list_options options=queryOptions scope="Query" />
         </div>
       </div>
     </div>
@@ -527,4 +512,28 @@ table.sortable thead .sorting_desc { background-image: url("/static/img/black-de
 
 </#macro>
 
+<#macro list_options options scope>
+ <#if (options?keys?size > 0) >
+   <div class="panel-body">
+     <h4>${scope} Options</h4>
+     <table id="${scope}_options_table" class="table table-bordered">
+       <thead>
+         <tr>
+           <th>Name</th>
+           <th>Value</th>
+         </tr>
+       </thead>
+         <tbody>
+           <#list options?keys as name>
+             <tr>
+               <td>${name}</td>
+               <td>${options[name]}</td>
+             </tr>
+           </#list>
+         </tbody>
+     </table>
+   </div>
+ </#if>
+</#macro>
+
 <@page_html/>


[drill] 01/03: DRILL-6925: Unable to generate Protobuf

Posted by vi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

vitalii pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/drill.git

commit 4a771d0af83beccbb0a7fc9f03b22966c1292724
Author: Vitalii Diravka <vi...@gmail.com>
AuthorDate: Sun Dec 23 22:51:15 2018 +0200

    DRILL-6925: Unable to generate Protobuf
    
    - use ${maven.multiModuleProjectDirectory}/header to find header file from any submodule
    - suppress UnresolvedMavenProperty, since IDE expects that property should be set explicitly
    - update "kr.motd.maven:os-maven-plugin" github.com/trustin/os-maven-plugin to the latest 1.6.1 version
    - correction of ${user.name} propery for "maven-jar-plugin" <Built-By>
    - update "apache-rat-plugin" to solve undefined "excludeSubprojects" in IDE
    - regenerate Java and C++ protobuf files
    
    closes #1585
---
 .mvn/extensions.xml                                |  2 +-
 contrib/native/client/src/protobuf/BitData.pb.cc   | 56 +++++++++++++++++++---
 contrib/native/client/src/protobuf/BitData.pb.h    | 34 ++++++++++++-
 .../org/apache/drill/exec/ssl/SSLConfigClient.java |  4 +-
 .../org/apache/drill/exec/ssl/SSLConfigServer.java |  4 +-
 pom.xml                                            | 10 ++--
 .../org/apache/drill/exec/proto/UserBitShared.java | 40 ++++++++++++++++
 7 files changed, 133 insertions(+), 17 deletions(-)

diff --git a/.mvn/extensions.xml b/.mvn/extensions.xml
index bf8c8c7..cee0598 100644
--- a/.mvn/extensions.xml
+++ b/.mvn/extensions.xml
@@ -22,6 +22,6 @@ under the License.
   <extension>
     <groupId>kr.motd.maven</groupId>
     <artifactId>os-maven-plugin</artifactId>
-    <version>1.5.0.Final</version>
+    <version>1.6.1</version>
   </extension>
 </extensions>
diff --git a/contrib/native/client/src/protobuf/BitData.pb.cc b/contrib/native/client/src/protobuf/BitData.pb.cc
index ddee323..df2207a 100644
--- a/contrib/native/client/src/protobuf/BitData.pb.cc
+++ b/contrib/native/client/src/protobuf/BitData.pb.cc
@@ -99,7 +99,7 @@ void protobuf_AssignDesc_BitData_2eproto() {
       ::google::protobuf::MessageFactory::generated_factory(),
       sizeof(FragmentRecordBatch));
   RuntimeFilterBDef_descriptor_ = file->message_type(3);
-  static const int RuntimeFilterBDef_offsets_[7] = {
+  static const int RuntimeFilterBDef_offsets_[8] = {
     GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(RuntimeFilterBDef, query_id_),
     GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(RuntimeFilterBDef, major_fragment_id_),
     GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(RuntimeFilterBDef, minor_fragment_id_),
@@ -107,6 +107,7 @@ void protobuf_AssignDesc_BitData_2eproto() {
     GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(RuntimeFilterBDef, bloom_filter_size_in_bytes_),
     GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(RuntimeFilterBDef, probe_fields_),
     GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(RuntimeFilterBDef, hj_op_id_),
+    GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(RuntimeFilterBDef, rf_identifier_),
   };
   RuntimeFilterBDef_reflection_ =
     new ::google::protobuf::internal::GeneratedMessageReflection(
@@ -178,16 +179,17 @@ void protobuf_AddDesc_BitData_2eproto() {
     " \003(\005\022!\n\031sending_major_fragment_id\030\004 \001(\005\022"
     "!\n\031sending_minor_fragment_id\030\005 \001(\005\022(\n\003de"
     "f\030\006 \001(\0132\033.exec.shared.RecordBatchDef\022\023\n\013"
-    "isLastBatch\030\007 \001(\010\"\321\001\n\021RuntimeFilterBDef\022"
+    "isLastBatch\030\007 \001(\010\"\350\001\n\021RuntimeFilterBDef\022"
     "&\n\010query_id\030\001 \001(\0132\024.exec.shared.QueryId\022"
     "\031\n\021major_fragment_id\030\002 \001(\005\022\031\n\021minor_frag"
     "ment_id\030\003 \001(\005\022\022\n\nto_foreman\030\004 \001(\010\022\"\n\032blo"
     "om_filter_size_in_bytes\030\005 \003(\005\022\024\n\014probe_f"
-    "ields\030\006 \003(\t\022\020\n\010hj_op_id\030\007 \001(\005*n\n\007RpcType"
-    "\022\r\n\tHANDSHAKE\020\000\022\007\n\003ACK\020\001\022\013\n\007GOODBYE\020\002\022\024\n"
-    "\020REQ_RECORD_BATCH\020\003\022\020\n\014SASL_MESSAGE\020\004\022\026\n"
-    "\022REQ_RUNTIME_FILTER\020\005B(\n\033org.apache.dril"
-    "l.exec.protoB\007BitDataH\001", 903);
+    "ields\030\006 \003(\t\022\020\n\010hj_op_id\030\007 \001(\005\022\025\n\rrf_iden"
+    "tifier\030\010 \001(\003*n\n\007RpcType\022\r\n\tHANDSHAKE\020\000\022\007"
+    "\n\003ACK\020\001\022\013\n\007GOODBYE\020\002\022\024\n\020REQ_RECORD_BATCH"
+    "\020\003\022\020\n\014SASL_MESSAGE\020\004\022\026\n\022REQ_RUNTIME_FILT"
+    "ER\020\005B(\n\033org.apache.drill.exec.protoB\007Bit"
+    "DataH\001", 926);
   ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile(
     "BitData.proto", &protobuf_RegisterTypes);
   BitClientHandshake::default_instance_ = new BitClientHandshake();
@@ -1210,6 +1212,7 @@ const int RuntimeFilterBDef::kToForemanFieldNumber;
 const int RuntimeFilterBDef::kBloomFilterSizeInBytesFieldNumber;
 const int RuntimeFilterBDef::kProbeFieldsFieldNumber;
 const int RuntimeFilterBDef::kHjOpIdFieldNumber;
+const int RuntimeFilterBDef::kRfIdentifierFieldNumber;
 #endif  // !_MSC_VER
 
 RuntimeFilterBDef::RuntimeFilterBDef()
@@ -1234,6 +1237,7 @@ void RuntimeFilterBDef::SharedCtor() {
   minor_fragment_id_ = 0;
   to_foreman_ = false;
   hj_op_id_ = 0;
+  rf_identifier_ = GOOGLE_LONGLONG(0);
   ::memset(_has_bits_, 0, sizeof(_has_bits_));
 }
 
@@ -1277,6 +1281,7 @@ void RuntimeFilterBDef::Clear() {
     minor_fragment_id_ = 0;
     to_foreman_ = false;
     hj_op_id_ = 0;
+    rf_identifier_ = GOOGLE_LONGLONG(0);
   }
   bloom_filter_size_in_bytes_.Clear();
   probe_fields_.Clear();
@@ -1404,6 +1409,22 @@ bool RuntimeFilterBDef::MergePartialFromCodedStream(
         } else {
           goto handle_uninterpreted;
         }
+        if (input->ExpectTag(64)) goto parse_rf_identifier;
+        break;
+      }
+
+      // optional int64 rf_identifier = 8;
+      case 8: {
+        if (::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) ==
+            ::google::protobuf::internal::WireFormatLite::WIRETYPE_VARINT) {
+         parse_rf_identifier:
+          DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive<
+                   ::google::protobuf::int64, ::google::protobuf::internal::WireFormatLite::TYPE_INT64>(
+                 input, &rf_identifier_)));
+          set_has_rf_identifier();
+        } else {
+          goto handle_uninterpreted;
+        }
         if (input->ExpectAtEnd()) return true;
         break;
       }
@@ -1467,6 +1488,11 @@ void RuntimeFilterBDef::SerializeWithCachedSizes(
     ::google::protobuf::internal::WireFormatLite::WriteInt32(7, this->hj_op_id(), output);
   }
 
+  // optional int64 rf_identifier = 8;
+  if (has_rf_identifier()) {
+    ::google::protobuf::internal::WireFormatLite::WriteInt64(8, this->rf_identifier(), output);
+  }
+
   if (!unknown_fields().empty()) {
     ::google::protobuf::internal::WireFormat::SerializeUnknownFields(
         unknown_fields(), output);
@@ -1517,6 +1543,11 @@ void RuntimeFilterBDef::SerializeWithCachedSizes(
     target = ::google::protobuf::internal::WireFormatLite::WriteInt32ToArray(7, this->hj_op_id(), target);
   }
 
+  // optional int64 rf_identifier = 8;
+  if (has_rf_identifier()) {
+    target = ::google::protobuf::internal::WireFormatLite::WriteInt64ToArray(8, this->rf_identifier(), target);
+  }
+
   if (!unknown_fields().empty()) {
     target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
         unknown_fields(), target);
@@ -1561,6 +1592,13 @@ int RuntimeFilterBDef::ByteSize() const {
           this->hj_op_id());
     }
 
+    // optional int64 rf_identifier = 8;
+    if (has_rf_identifier()) {
+      total_size += 1 +
+        ::google::protobuf::internal::WireFormatLite::Int64Size(
+          this->rf_identifier());
+    }
+
   }
   // repeated int32 bloom_filter_size_in_bytes = 5;
   {
@@ -1622,6 +1660,9 @@ void RuntimeFilterBDef::MergeFrom(const RuntimeFilterBDef& from) {
     if (from.has_hj_op_id()) {
       set_hj_op_id(from.hj_op_id());
     }
+    if (from.has_rf_identifier()) {
+      set_rf_identifier(from.rf_identifier());
+    }
   }
   mutable_unknown_fields()->MergeFrom(from.unknown_fields());
 }
@@ -1652,6 +1693,7 @@ void RuntimeFilterBDef::Swap(RuntimeFilterBDef* other) {
     bloom_filter_size_in_bytes_.Swap(&other->bloom_filter_size_in_bytes_);
     probe_fields_.Swap(&other->probe_fields_);
     std::swap(hj_op_id_, other->hj_op_id_);
+    std::swap(rf_identifier_, other->rf_identifier_);
     std::swap(_has_bits_[0], other->_has_bits_[0]);
     _unknown_fields_.Swap(&other->_unknown_fields_);
     std::swap(_cached_size_, other->_cached_size_);
diff --git a/contrib/native/client/src/protobuf/BitData.pb.h b/contrib/native/client/src/protobuf/BitData.pb.h
index 7ee0bc6..9c9c42f 100644
--- a/contrib/native/client/src/protobuf/BitData.pb.h
+++ b/contrib/native/client/src/protobuf/BitData.pb.h
@@ -528,6 +528,13 @@ class RuntimeFilterBDef : public ::google::protobuf::Message {
   inline ::google::protobuf::int32 hj_op_id() const;
   inline void set_hj_op_id(::google::protobuf::int32 value);
 
+  // optional int64 rf_identifier = 8;
+  inline bool has_rf_identifier() const;
+  inline void clear_rf_identifier();
+  static const int kRfIdentifierFieldNumber = 8;
+  inline ::google::protobuf::int64 rf_identifier() const;
+  inline void set_rf_identifier(::google::protobuf::int64 value);
+
   // @@protoc_insertion_point(class_scope:exec.bit.data.RuntimeFilterBDef)
  private:
   inline void set_has_query_id();
@@ -540,6 +547,8 @@ class RuntimeFilterBDef : public ::google::protobuf::Message {
   inline void clear_has_to_foreman();
   inline void set_has_hj_op_id();
   inline void clear_has_hj_op_id();
+  inline void set_has_rf_identifier();
+  inline void clear_has_rf_identifier();
 
   ::google::protobuf::UnknownFieldSet _unknown_fields_;
 
@@ -550,9 +559,10 @@ class RuntimeFilterBDef : public ::google::protobuf::Message {
   bool to_foreman_;
   ::google::protobuf::int32 hj_op_id_;
   ::google::protobuf::RepeatedPtrField< ::std::string> probe_fields_;
+  ::google::protobuf::int64 rf_identifier_;
 
   mutable int _cached_size_;
-  ::google::protobuf::uint32 _has_bits_[(7 + 31) / 32];
+  ::google::protobuf::uint32 _has_bits_[(8 + 31) / 32];
 
   friend void  protobuf_AddDesc_BitData_2eproto();
   friend void protobuf_AssignDesc_BitData_2eproto();
@@ -1075,6 +1085,28 @@ inline void RuntimeFilterBDef::set_hj_op_id(::google::protobuf::int32 value) {
   hj_op_id_ = value;
 }
 
+// optional int64 rf_identifier = 8;
+inline bool RuntimeFilterBDef::has_rf_identifier() const {
+  return (_has_bits_[0] & 0x00000080u) != 0;
+}
+inline void RuntimeFilterBDef::set_has_rf_identifier() {
+  _has_bits_[0] |= 0x00000080u;
+}
+inline void RuntimeFilterBDef::clear_has_rf_identifier() {
+  _has_bits_[0] &= ~0x00000080u;
+}
+inline void RuntimeFilterBDef::clear_rf_identifier() {
+  rf_identifier_ = GOOGLE_LONGLONG(0);
+  clear_has_rf_identifier();
+}
+inline ::google::protobuf::int64 RuntimeFilterBDef::rf_identifier() const {
+  return rf_identifier_;
+}
+inline void RuntimeFilterBDef::set_rf_identifier(::google::protobuf::int64 value) {
+  set_has_rf_identifier();
+  rf_identifier_ = value;
+}
+
 
 // @@protoc_insertion_point(namespace_scope)
 
diff --git a/exec/java-exec/src/main/java/org/apache/drill/exec/ssl/SSLConfigClient.java b/exec/java-exec/src/main/java/org/apache/drill/exec/ssl/SSLConfigClient.java
index 1cc818c..681eb86 100644
--- a/exec/java-exec/src/main/java/org/apache/drill/exec/ssl/SSLConfigClient.java
+++ b/exec/java-exec/src/main/java/org/apache/drill/exec/ssl/SSLConfigClient.java
@@ -67,9 +67,9 @@ public class SSLConfigClient extends SSLConfig {
     // the dependency on netty-tcnative with the correct classifier for the platform you use.
     // This can be done by enabling the openssl profile.
     // If the IDE is Eclipse, it requires you to install an additional Eclipse plugin available here:
-    // http://repo1.maven.org/maven2/kr/motd/maven/os-maven-plugin/1.5.0.Final/os-maven-plugin-1.5.0.Final.jar
+    // http://repo1.maven.org/maven2/kr/motd/maven/os-maven-plugin/1.6.1/os-maven-plugin-1.6.1.jar
     // or from your local maven repository:
-    // ~/.m2/repository/kr/motd/maven/os-maven-plugin/1.5.0.Final/os-maven-plugin-1.5.0.Final.jar
+    // ~/.m2/repository/kr/motd/maven/os-maven-plugin/1.6.1/os-maven-plugin-1.6.1.jar
     // Note that installing this plugin may require you to start with a new workspace
     provider = getStringProperty(DrillProperties.TLS_PROVIDER, DEFAULT_SSL_PROVIDER);
   }
diff --git a/exec/java-exec/src/main/java/org/apache/drill/exec/ssl/SSLConfigServer.java b/exec/java-exec/src/main/java/org/apache/drill/exec/ssl/SSLConfigServer.java
index 674df42..e0b8f54 100644
--- a/exec/java-exec/src/main/java/org/apache/drill/exec/ssl/SSLConfigServer.java
+++ b/exec/java-exec/src/main/java/org/apache/drill/exec/ssl/SSLConfigServer.java
@@ -95,9 +95,9 @@ public class SSLConfigServer extends SSLConfig {
     // the dependency on netty-tcnative with the correct classifier for the platform you use.
     // This can be done by enabling the openssl profile.
     // If the IDE is Eclipse, it requires you to install an additional Eclipse plugin available here:
-    // http://repo1.maven.org/maven2/kr/motd/maven/os-maven-plugin/1.5.0.Final/os-maven-plugin-1.5.0.Final.jar
+    // http://repo1.maven.org/maven2/kr/motd/maven/os-maven-plugin/1.6.1/os-maven-plugin-1.6.1.jar
     // or from your local maven repository:
-    // ~/.m2/repository/kr/motd/maven/os-maven-plugin/1.5.0.Final/os-maven-plugin-1.5.0.Final.jar
+    // ~/.m2/repository/kr/motd/maven/os-maven-plugin/1.6.1/os-maven-plugin-1.6.1.jar
     // Note that installing this plugin may require you to start with a new workspace
     provider = getConfigParamWithDefault(ExecConstants.SSL_PROVIDER, DEFAULT_SSL_PROVIDER);
   }
diff --git a/pom.xml b/pom.xml
index e9b9693..97514f9 100644
--- a/pom.xml
+++ b/pom.xml
@@ -320,6 +320,7 @@
       <plugin>
         <groupId>org.apache.rat</groupId>
         <artifactId>apache-rat-plugin</artifactId>
+        <version>0.13</version>
         <executions>
           <execution>
             <id>rat-checks</id>
@@ -446,7 +447,7 @@
             </manifest>
             <manifestEntries>
               <Extension-Name>org.apache.drill</Extension-Name>
-              <Built-By>${username}</Built-By>
+              <Built-By>${user.name}</Built-By>
               <url>http://drill.apache.org/</url>
             </manifestEntries>
           </archive>
@@ -587,7 +588,8 @@
           <version>3.0</version>
           <configuration>
             <aggregate>true</aggregate>
-            <header>header</header>
+            <!--suppress UnresolvedMavenProperty -->
+            <header>${maven.multiModuleProjectDirectory}/header</header>
             <excludes>
               <exclude>**/clientlib/y2038/*.c</exclude> <!-- All the files here should have MIT License -->
               <exclude>**/clientlib/y2038/*.h</exclude> <!-- All the files here should have MIT License -->
@@ -3349,9 +3351,9 @@
     <profile>
       <!--
         If the IDE is Eclipse, it requires you to install an additional Eclipse plugin available here:
-        http://repo1.maven.org/maven2/kr/motd/maven/os-maven-plugin/1.5.0.Final/os-maven-plugin-1.5.0.Final.jar
+        http://repo1.maven.org/maven2/kr/motd/maven/os-maven-plugin/1.6.1/os-maven-plugin-1.6.1.jar
         or from your local maven repository:
-        ~/.m2/repository/kr/motd/maven/os-maven-plugin/1.5.0.Final/os-maven-plugin-1.5.0.Final.jar
+        ~/.m2/repository/kr/motd/maven/os-maven-plugin/1.6.1/os-maven-plugin-1.6.1.jar
         Note that installing this plugin may require you to start with a new workspace
       -->
       <id>openssl</id>
diff --git a/protocol/src/main/java/org/apache/drill/exec/proto/UserBitShared.java b/protocol/src/main/java/org/apache/drill/exec/proto/UserBitShared.java
index f969639..34fb47e 100644
--- a/protocol/src/main/java/org/apache/drill/exec/proto/UserBitShared.java
+++ b/protocol/src/main/java/org/apache/drill/exec/proto/UserBitShared.java
@@ -6800,10 +6800,20 @@ public final class UserBitShared {
     // optional int32 affected_rows_count = 4;
     /**
      * <code>optional int32 affected_rows_count = 4;</code>
+     *
+     * <pre>
+     * The value is set when result set is disabled and its value corresponds to number
+     * of rows affected by query (see JDBC java.sql.ResultSet#getUpdateCount())
+     * </pre>
      */
     boolean hasAffectedRowsCount();
     /**
      * <code>optional int32 affected_rows_count = 4;</code>
+     *
+     * <pre>
+     * The value is set when result set is disabled and its value corresponds to number
+     * of rows affected by query (see JDBC java.sql.ResultSet#getUpdateCount())
+     * </pre>
      */
     int getAffectedRowsCount();
   }
@@ -6997,12 +7007,22 @@ public final class UserBitShared {
     private int affectedRowsCount_;
     /**
      * <code>optional int32 affected_rows_count = 4;</code>
+     *
+     * <pre>
+     * The value is set when result set is disabled and its value corresponds to number
+     * of rows affected by query (see JDBC java.sql.ResultSet#getUpdateCount())
+     * </pre>
      */
     public boolean hasAffectedRowsCount() {
       return ((bitField0_ & 0x00000004) == 0x00000004);
     }
     /**
      * <code>optional int32 affected_rows_count = 4;</code>
+     *
+     * <pre>
+     * The value is set when result set is disabled and its value corresponds to number
+     * of rows affected by query (see JDBC java.sql.ResultSet#getUpdateCount())
+     * </pre>
      */
     public int getAffectedRowsCount() {
       return affectedRowsCount_;
@@ -7629,18 +7649,33 @@ public final class UserBitShared {
       private int affectedRowsCount_ ;
       /**
        * <code>optional int32 affected_rows_count = 4;</code>
+       *
+       * <pre>
+       * The value is set when result set is disabled and its value corresponds to number
+       * of rows affected by query (see JDBC java.sql.ResultSet#getUpdateCount())
+       * </pre>
        */
       public boolean hasAffectedRowsCount() {
         return ((bitField0_ & 0x00000008) == 0x00000008);
       }
       /**
        * <code>optional int32 affected_rows_count = 4;</code>
+       *
+       * <pre>
+       * The value is set when result set is disabled and its value corresponds to number
+       * of rows affected by query (see JDBC java.sql.ResultSet#getUpdateCount())
+       * </pre>
        */
       public int getAffectedRowsCount() {
         return affectedRowsCount_;
       }
       /**
        * <code>optional int32 affected_rows_count = 4;</code>
+       *
+       * <pre>
+       * The value is set when result set is disabled and its value corresponds to number
+       * of rows affected by query (see JDBC java.sql.ResultSet#getUpdateCount())
+       * </pre>
        */
       public Builder setAffectedRowsCount(int value) {
         bitField0_ |= 0x00000008;
@@ -7650,6 +7685,11 @@ public final class UserBitShared {
       }
       /**
        * <code>optional int32 affected_rows_count = 4;</code>
+       *
+       * <pre>
+       * The value is set when result set is disabled and its value corresponds to number
+       * of rows affected by query (see JDBC java.sql.ResultSet#getUpdateCount())
+       * </pre>
        */
       public Builder clearAffectedRowsCount() {
         bitField0_ = (bitField0_ & ~0x00000008);


[drill] 03/03: DRILL-6920: Fix TestClient.testBasics() yarn test failure

Posted by vi...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

vitalii pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/drill.git

commit 3e2d6192fc346fe63342021e5d19c7921d6c59dd
Author: Volodymyr Vysotskyi <vv...@gmail.com>
AuthorDate: Fri Dec 21 14:37:45 2018 +0200

    DRILL-6920: Fix TestClient.testBasics() yarn test failure
    
    closes #1582
---
 .../test/java/org/apache/drill/yarn/client/TestClient.java   | 12 ++----------
 1 file changed, 2 insertions(+), 10 deletions(-)

diff --git a/drill-yarn/src/test/java/org/apache/drill/yarn/client/TestClient.java b/drill-yarn/src/test/java/org/apache/drill/yarn/client/TestClient.java
index 73f1b00..8be3148 100644
--- a/drill-yarn/src/test/java/org/apache/drill/yarn/client/TestClient.java
+++ b/drill-yarn/src/test/java/org/apache/drill/yarn/client/TestClient.java
@@ -105,6 +105,7 @@ public class TestClient {
     } catch (SimulatedExitException e) {
       assert (e.exitCode == -1);
       assertTrue(TestContext.getOut().contains("Usage: "));
+      TestContext.resetOutput();
     }
 
     // Bogus command
@@ -115,16 +116,7 @@ public class TestClient {
     } catch (SimulatedExitException e) {
       assert (e.exitCode == -1);
       assertTrue(TestContext.getOut().contains("Usage: "));
-    }
-
-    // Help command
-
-    try {
-      DrillOnYarn.run(new String[] { "help" });
-      fail();
-    } catch (SimulatedExitException e) {
-      assert (e.exitCode == -1);
-      assertTrue(TestContext.getOut().contains("Usage: "));
+      TestContext.resetOutput();
     }
   }