You are viewing a plain text version of this content. The canonical link for it is here.
Posted to gitbox@hive.apache.org by GitBox <gi...@apache.org> on 2020/07/07 07:03:15 UTC

[GitHub] [hive] kgyrtkirk opened a new pull request #1215: HIVE-23806 avoid stat clear

kgyrtkirk opened a new pull request #1215:
URL: https://github.com/apache/hive/pull/1215


   


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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@hive.apache.org
For additional commands, e-mail: gitbox-help@hive.apache.org


[GitHub] [hive] adesh-rao commented on a change in pull request #1215: HIVE-23806: Avoid clearing column stat states in all partition in case schema is extended

Posted by GitBox <gi...@apache.org>.
adesh-rao commented on a change in pull request #1215:
URL: https://github.com/apache/hive/pull/1215#discussion_r452724372



##########
File path: standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/utils/MetaStoreServerUtils.java
##########
@@ -501,6 +502,28 @@ public static boolean areSameColumns(List<FieldSchema> oldCols, List<FieldSchema
     return ListUtils.isEqualList(oldCols, newCols);
   }
 
+  /**
+   * Returns true if p is a prefix of s.
+   */
+  public static boolean arePrefixColumns(List<FieldSchema> p, List<FieldSchema> s) {
+    if (p == s) {
+      return true;
+    }
+    if (p.size() > s.size()) {
+      return false;
+    }
+    Iterator itP = p.iterator();

Review comment:
       @kgyrtkirk Maybe we can use `ListUtils.isEqualList(p, p.subList(0, p.size()))`? that way we can avoid most of the code here?




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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@hive.apache.org
For additional commands, e-mail: gitbox-help@hive.apache.org


[GitHub] [hive] kgyrtkirk merged pull request #1215: HIVE-23806: Avoid clearing column stat states in all partition in case schema is extended

Posted by GitBox <gi...@apache.org>.
kgyrtkirk merged pull request #1215:
URL: https://github.com/apache/hive/pull/1215


   


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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@hive.apache.org
For additional commands, e-mail: gitbox-help@hive.apache.org


[GitHub] [hive] kgyrtkirk commented on a change in pull request #1215: HIVE-23806: Avoid clearing column stat states in all partition in case schema is extended

Posted by GitBox <gi...@apache.org>.
kgyrtkirk commented on a change in pull request #1215:
URL: https://github.com/apache/hive/pull/1215#discussion_r453592530



##########
File path: standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/utils/MetaStoreServerUtils.java
##########
@@ -501,6 +502,28 @@ public static boolean areSameColumns(List<FieldSchema> oldCols, List<FieldSchema
     return ListUtils.isEqualList(oldCols, newCols);
   }
 
+  /**
+   * Returns true if p is a prefix of s.
+   */
+  public static boolean arePrefixColumns(List<FieldSchema> p, List<FieldSchema> s) {
+    if (p == s) {
+      return true;
+    }
+    if (p.size() > s.size()) {
+      return false;
+    }
+    Iterator itP = p.iterator();

Review comment:
       of course! :)




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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@hive.apache.org
For additional commands, e-mail: gitbox-help@hive.apache.org


[GitHub] [hive] adesh-rao commented on a change in pull request #1215: HIVE-23806: Avoid clearing column stat states in all partition in case schema is extended

Posted by GitBox <gi...@apache.org>.
adesh-rao commented on a change in pull request #1215:
URL: https://github.com/apache/hive/pull/1215#discussion_r452724372



##########
File path: standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/utils/MetaStoreServerUtils.java
##########
@@ -501,6 +502,28 @@ public static boolean areSameColumns(List<FieldSchema> oldCols, List<FieldSchema
     return ListUtils.isEqualList(oldCols, newCols);
   }
 
+  /**
+   * Returns true if p is a prefix of s.
+   */
+  public static boolean arePrefixColumns(List<FieldSchema> p, List<FieldSchema> s) {
+    if (p == s) {
+      return true;
+    }
+    if (p.size() > s.size()) {
+      return false;
+    }
+    Iterator itP = p.iterator();

Review comment:
       @kgyrtkirk Maybe we can use `ListUtils.isEqualList(p, s.subList(0, p.size()))`? that way we can avoid most of the code here?




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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@hive.apache.org
For additional commands, e-mail: gitbox-help@hive.apache.org