Sugamber commented on issue #2637:
URL: https://github.com/apache/hudi/issues/2637#issuecomment-797307517
@n3nash How can we pass custom class name? I copied same class as
CustomRecordUpdate and tried to set during save. It throws class not found
exception.
` writeDF.write.format("org.apache.hudi")
.options(hudiConfMap)
.option("hoodie.datasource.write.payload.class",
classOf[CustomRecordUpdate].getName)
.option(DataSourceWriteOptions.RECORDKEY_FIELD_OPT_KEY, "col1")
.option(DataSourceWriteOptions.PARTITIONPATH_FIELD_OPT_KEY, "col2")
.option(DataSourceWriteOptions.PRECOMBINE_FIELD_OPT_KEY, "col3")
.option(HoodieWriteConfig.TABLE_NAME, tableName.toString)
.mode(SaveMode.Append)
.save(tablePath.toString)`
I tried all three ways of scala api but non of them worked.
`classOf[CustomRecordUpdate].getCanonicalName
classOf[CustomRecordUpdate].getName
classOf[CustomRecordUpdate].getSimpleName`
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]