CTTY commented on code in PR #12848:
URL: https://github.com/apache/hudi/pull/12848#discussion_r1966629801
##########
hudi-spark-datasource/hudi-spark-common/src/main/scala/org/apache/spark/sql/hudi/command/AlterHoodieTableRenameCommand.scala:
##########
@@ -52,8 +52,7 @@ case class AlterHoodieTableRenameCommand(
// update table properties path in every op
if (hoodieCatalogTable.table.properties.contains("path")) {
val catalogTable =
sparkSession.sessionState.catalog.getTableMetadata(newName)
- val path = catalogTable.storage.locationUri.get.getPath
- AlterTableSetPropertiesCommand(newName, Map("path" -> path),
isView).run(sparkSession)
+ AlterTableSetPropertiesCommand(newName, Map("path" ->
catalogTable.location.toString), isView).run(sparkSession)
Review Comment:
No, data files will not be relocated. The issue happened because how we set
the path in `AlterHoodieTableRenameCommand` may strip the scheme and authority
of path in some cases.
--
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]