hudi-bot opened a new issue, #16250:
URL: https://github.com/apache/hudi/issues/16250

   Hudi can't infer default database name when running hive sync.
   
    
   "hoodie.datasource.hive_sync.database" has a default value of "default" but 
it would use infer function to read "hoodie.database.name" before using default 
value.
    
   And "hoodie.database.name" is set to an empty string by default, which is 
considered non-null by java `Option` class so Hudi would continue to use the 
empty string instead of "default" to run hive sync, and cause exceptions below:
    
   {code:java}
   Caused by: org.apache.hudi.exception.HoodieException: Got runtime exception 
when hive syncing hudi_basic_test_mor51667
     at org.apache.hudi.hive.HiveSyncTool.syncHoodieTable(HiveSyncTool.java:168)
     at 
org.apache.hudi.sync.common.util.SyncUtilHelpers.runHoodieMetaSync(SyncUtilHelpers.java:79)
     ... 90 more
   Caused by: java.lang.IllegalArgumentException: databaseName cannot be null 
or empty
     at 
com.google.common.base.Preconditions.checkArgument(Preconditions.java:92)
     at 
com.amazonaws.glue.catalog.metastore.GlueMetastoreClientDelegate.tableExists(GlueMetastoreClientDelegate.java:417)
     at 
com.amazonaws.glue.catalog.metastore.AWSCatalogMetastoreClient.tableExists(AWSCatalogMetastoreClient.java:1644)
     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
     at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
     at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
     at java.lang.reflect.Method.invoke(Method.java:498)
     at 
org.apache.hadoop.hive.metastore.HiveMetaStoreClient$SynchronizedHandler.invoke(HiveMetaStoreClient.java:2350)
     at com.sun.proxy.$Proxy89.tableExists(Unknown Source)
     at 
org.apache.hudi.hive.HoodieHiveSyncClient.tableExists(HoodieHiveSyncClient.java:250)
     at org.apache.hudi.hive.HiveSyncTool.syncHoodieTable(HiveSyncTool.java:241)
     at org.apache.hudi.hive.HiveSyncTool.doSync(HiveSyncTool.java:191)
     at 
org.apache.hudi.hive.HiveSyncTool.syncHoodieTable(HiveSyncTool.java:165) {code}
   
   ## JIRA info
   
   - Link: https://issues.apache.org/jira/browse/HUDI-6913
   - Type: Bug


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

Reply via email to