You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kudu.apache.org by gr...@apache.org on 2018/05/31 18:18:21 UTC

[2/3] kudu git commit: KUDU-2191: Leave table type as it is when populate a table

KUDU-2191: Leave table type as it is when populate a table

Now in HmsCatalog we always set table type to be managed when
populating a table. However, PopulateTable() is used in AlterTable as
well which implies the table type for existing tables in the Hive
Metastore may change without users' knowledge. Moreover,
PopulateTable() can be used in the metadata consistency check tool,
which may result in validation failure for external tables, though
there is none.

By default, when creating a table in the Hive Metastore, the table type
is managed without specifying the type. Thus, there is not much value
to specify it anyway.

Change-Id: I8cff392802308a5ea6262c17d248d37e00ac8190
Reviewed-on: http://gerrit.cloudera.org:8080/10477
Tested-by: Kudu Jenkins
Reviewed-by: Dan Burkert <da...@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/kudu/repo
Commit: http://git-wip-us.apache.org/repos/asf/kudu/commit/4883eeef
Tree: http://git-wip-us.apache.org/repos/asf/kudu/tree/4883eeef
Diff: http://git-wip-us.apache.org/repos/asf/kudu/diff/4883eeef

Branch: refs/heads/master
Commit: 4883eeef5249f87f827c8193456b33cc506f5aa4
Parents: d7af95b
Author: hahao <ha...@cloudera.com>
Authored: Mon May 21 17:42:06 2018 -0700
Committer: Hao Hao <ha...@cloudera.com>
Committed: Thu May 31 00:51:00 2018 +0000

----------------------------------------------------------------------
 src/kudu/hms/hms_catalog.cc | 1 -
 1 file changed, 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/kudu/blob/4883eeef/src/kudu/hms/hms_catalog.cc
----------------------------------------------------------------------
diff --git a/src/kudu/hms/hms_catalog.cc b/src/kudu/hms/hms_catalog.cc
index 05370dc..944eecd 100644
--- a/src/kudu/hms/hms_catalog.cc
+++ b/src/kudu/hms/hms_catalog.cc
@@ -421,7 +421,6 @@ Status HmsCatalog::PopulateTable(const string& id,
                                  const string& master_addresses,
                                  hive::Table* table) {
   RETURN_NOT_OK(ParseTableName(name, &table->dbName, &table->tableName));
-  table->tableType = HmsClient::kManagedTable;
 
   // Add the Kudu-specific parameters. This intentionally avoids overwriting
   // other parameters.