[HUDI-5317] Fix insert overwrite table for partitioned table#8015
[HUDI-5317] Fix insert overwrite table for partitioned table#8015stream2000 wants to merge 3 commits intoapache:masterfrom
Conversation
f0dcc31 to
997d2a9
Compare
997d2a9 to
8aa97ff
Compare
|
@stream2000 Hi, I'm quite confused with the behavior here, for if (mode == SaveMode.Overwrite && tableExists && operation != WriteOperationType.INSERT_OVERWRITE_TABLE) {
// When user set operation as INSERT_OVERWRITE_TABLE,
// overwrite will use INSERT_OVERWRITE_TABLE operator in doWriteOperation
log.warn(s"hoodie table at $tablePath already exists. Deleting existing data & overwriting with new data.")
fs.delete(tablePath, true)
tableExists = false
}while for I'm thinking we should firstly don't allow for |
I agree that we should unify the semantics between insert overwrite partition and insert overwrite table when bulk_insert is enabled. I will push a commit later that directly throw exception when bulk_insert is enabled in insert overwrite table/partittion. cc @leesf |
Change Logs
fix #7365, when hoodie.sql.bulk.insert.enable = true and hoodie.schema.on.read.enable=true, insert overwrite on non-partition table will fail because the save mode is set Append not Overwrite.
After this pr both insert overwrite table and insert overwrite partition can not use bulk insert
Impact
both insert overwrite table and insert overwrite partition can not use bulk insert
Risk level (write none, low medium or high below)
low
Documentation Update
None
Contributor's checklist