saihemanth-cloudera commented on code in PR #3482:
URL: https://github.com/apache/hive/pull/3482#discussion_r932198572


##########
jdbc-handler/src/main/java/org/apache/hive/storage/jdbc/JdbcStorageHandler.java:
##########
@@ -99,7 +101,10 @@ public void configureInputJobProperties(TableDesc 
tableDesc, Map<String, String>
   @Override
   public URI getURIForAuth(Table table) throws URISyntaxException {
     Map<String, String> tableProperties = 
HiveCustomStorageHandlerUtils.getTableProperties(table);
-    String host_url = tableProperties.get(Constants.JDBC_URL);
+    DatabaseType dbType = DatabaseType.valueOf(
+      tableProperties.get(JdbcStorageConfig.DATABASE_TYPE.getPropertyName()));
+    String host_url = DatabaseType.METASTORE == dbType ?
+      "internal:metastore://" : tableProperties.get(Constants.JDBC_URL);

Review Comment:
   All the storage handlers will have prefix in the Storage URL including jdbc 
storage handler. Can we make this hardcoded uri also to be in the same format? 
Essentially you would need to add "JDBC://" before the string 
"internal:metastore:/" (please take out extra "/" after "metastore:/")?



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to