github-actions[bot] commented on code in PR #64678:
URL: https://github.com/apache/doris/pull/64678#discussion_r3458015884
##########
be/src/exec/sink/writer/vhive_partition_writer.cpp:
##########
@@ -127,7 +127,8 @@ Status VHivePartitionWriter::close(const Status& status) {
}
bool status_ok = result_status.ok() && status.ok();
if (!status_ok && _fs != nullptr) {
- auto path = fmt::format("{}/{}", _write_info.write_path, _file_name);
+ // delete the actual created file, otherwise an orphan file is left
behind
+ auto path = fmt::format("{}/{}", _write_info.write_path,
_get_target_file_name());
Review Comment:
This still misses the Hive S3 case. `VHivePartitionWriter` always opens the
writer with `used_by_s3_committer = true`, so `S3FileWriter::close()` uploads
the parts and returns OK without completing the object; FE later completes or
aborts the MPU from the `TS3MPUPendingUpload` metadata built in
`_build_partition_update()`. On this failure branch, though, `status_ok` is
false, so `_build_partition_update()` is skipped and the only cleanup is
`delete_file(path)`. For an in-progress MPU there is no completed object at
this key yet, so `DeleteObject` is a no-op for the uploaded parts and FE
rollback never learns the upload id to abort it. Please either abort the
`S3FileWriter` MPU here for `FILE_S3`, or still propagate the pending MPU
metadata to the FE rollback path before skipping the normal partition update.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]