imay commented on a change in pull request #1297: Add copy function to support
storage migration task
URL: https://github.com/apache/incubator-doris/pull/1297#discussion_r293260962
##########
File path: be/src/olap/task/engine_storage_migration_task.cpp
##########
@@ -219,12 +219,16 @@ OLAPStatus
EngineStorageMigrationTask::_copy_index_and_data_files(
const string& schema_hash_path,
const TabletSharedPtr& ref_tablet,
std::vector<RowsetSharedPtr>& consistent_rowsets) {
- // TODO(lcy). copy function should be implemented
+ std::vector<std::string> success_files;
+ OLAPStatus status = OLAP_SUCCESS;
for (auto& rs : consistent_rowsets) {
- std::vector<std::string> success_files;
- RETURN_NOT_OK(rs->make_snapshot(schema_hash_path, &success_files));
+ status = rs->copy_files_to_path(schema_hash_path, &success_files);
+ if (status != OLAP_SUCCESS) {
+ while (OLAP_SUCCESS != remove_all_dir(schema_hash_path));
Review comment:
Don't dead loop here
----------------------------------------------------------------
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]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]