Skip to content
Permalink
Browse files
[fixbug]fix bug for OLAP_SUCCESS with Status (#9427)
  • Loading branch information
pengxiangyu committed May 11, 2022
1 parent e3bac86 commit 289608cc20703257043cbe1d4210a848b096fc30
Showing 2 changed files with 7 additions and 5 deletions.
@@ -352,9 +352,10 @@ Status StorageMigrationV2Handler::_convert_historical_rowsets(
goto PROCESS_ALTER_EXIT;
}

if ((res = _generate_rowset_writer(sm_params.base_tablet->tablet_path_desc(),
sm_params.new_tablet->tablet_path_desc(), rs_reader,
rowset_writer.get(), new_tablet)) != OLAP_SUCCESS) {
if (!(res = _generate_rowset_writer(sm_params.base_tablet->tablet_path_desc(),
sm_params.new_tablet->tablet_path_desc(), rs_reader,
rowset_writer.get(), new_tablet))
.ok()) {
LOG(WARNING) << "failed to add_rowset. version=" << rs_reader->version().first << "-"
<< rs_reader->version().second;
new_tablet->data_dir()->remove_pending_ids(ROWSET_ID_PREFIX +
@@ -1070,8 +1070,9 @@ void TabletManager::try_delete_unused_tablet_path(DataDir* data_dir, TTabletId t
if (!tablet_uid.empty() && !storage_name.empty()) {
segment_desc.storage_name = storage_name;
StorageParamPB storage_param;
if (StorageBackendMgr::instance()->get_storage_param(
storage_name, &storage_param) != OLAP_SUCCESS) {
if (!StorageBackendMgr::instance()
->get_storage_param(storage_name, &storage_param)
.ok()) {
LOG(WARNING) << "storage_name is invalid: " << storage_name;
return;
}

0 comments on commit 289608c

Please sign in to comment.