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 2022/12/02 00:19:59 UTC
[GitHub] [hive] saihemanth-cloudera commented on a diff in pull request #3799: HIVE-26767: Fix HIVE-24120 to work for custom databases
saihemanth-cloudera commented on code in PR #3799:
URL: https://github.com/apache/hive/pull/3799#discussion_r1037678532
##########
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/DatabaseProduct.java:
##########
@@ -77,8 +77,15 @@ public static DatabaseProduct determineDatabaseProduct(String productName,
Configuration conf) {
DbType dbt;
+ // Check if we are using an external database product
+ boolean isExternal = MetastoreConf.getBoolVar(conf, ConfVars.USE_CUSTOM_RDBMS);
+
if (theDatabaseProduct != null) {
- Preconditions.checkState(theDatabaseProduct.dbType == getDbType(productName));
+ dbt = getDbType(productName);
+ if (isExternal) {
+ dbt = DbType.CUSTOM;
+ }
+ Preconditions.checkState(theDatabaseProduct.dbType == dbt);
Review Comment:
Ack
--
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.
To unsubscribe, e-mail: gitbox-unsubscribe@hive.apache.org
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