yihua commented on code in PR #11740:
URL: https://github.com/apache/hudi/pull/11740#discussion_r1712073176
##########
hudi-spark-datasource/hudi-spark-common/src/main/scala/org/apache/hudi/HoodieSparkSqlWriter.scala:
##########
@@ -1018,6 +1018,11 @@ class HoodieSparkSqlWriterInternal {
val metaSyncSuccess = metaSync(spark,
HoodieWriterUtils.convertMapToHoodieConfig(parameters),
tableInstantInfo.basePath, schema)
+ if (!metaSyncSuccess && commitSuccess) {
+ log.error("Metadata sync operation failed, rolling back current
commit")
+ client.rollback(tableInstantInfo.instantTime)
Review Comment:
See my comment in the GH issue. If required, we can make this configurable;
but the default behavior should not roll back the completed transaction.
--
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]