Skip to content

Commit

Permalink
[improve](stack) do not report stack for -230 (#40716)
Browse files Browse the repository at this point in the history
  • Loading branch information
dataroaring authored Sep 18, 2024
1 parent 0cd00fe commit 538817a
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 8 deletions.
1 change: 1 addition & 0 deletions be/src/cloud/cloud_tablet.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ Status CloudTablet::capture_rs_readers(const Version& spec_version,
auto missed_versions = get_missed_versions(spec_version.second);
if (missed_versions.empty()) {
st.set_code(VERSION_ALREADY_MERGED); // Reset error code
st.append(" versions are already compacted, ");
}
st.append(" tablet_id=" + std::to_string(tablet_id()));
// clang-format off
Expand Down
4 changes: 2 additions & 2 deletions be/src/olap/tablet.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -856,8 +856,8 @@ Status Tablet::capture_consistent_versions_unlocked(const Version& spec_version,
<< ", version already has been merged. spec_version: " << spec_version
<< ", max_version: " << max_version_unlocked();
}
status = Status::Error<VERSION_ALREADY_MERGED>(
"missed_versions is empty, spec_version "
status = Status::Error<VERSION_ALREADY_MERGED, false>(
"versions are already compacted, spec_version "
"{}, max_version {}, tablet_id {}",
spec_version.second, max_version_unlocked(), tablet_id());
} else {
Expand Down
15 changes: 9 additions & 6 deletions be/src/olap/version_graph.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -566,8 +566,9 @@ void VersionGraph::_add_vertex_to_graph(int64_t vertex_value) {
Status VersionGraph::capture_consistent_versions(const Version& spec_version,
std::vector<Version>* version_path) const {
if (spec_version.first > spec_version.second) {
return Status::Error<INVALID_ARGUMENT>("invalid specified version. spec_version={}-{}",
spec_version.first, spec_version.second);
return Status::Error<INVALID_ARGUMENT, false>(
"invalid specified version. spec_version={}-{}", spec_version.first,
spec_version.second);
}

int64_t cur_idx = -1;
Expand All @@ -579,8 +580,9 @@ Status VersionGraph::capture_consistent_versions(const Version& spec_version,
}

if (cur_idx < 0) {
return Status::InternalError("failed to find path in version_graph. spec_version: {}-{}",
spec_version.first, spec_version.second);
return Status::InternalError<false>(
"failed to find path in version_graph. spec_version: {}-{}", spec_version.first,
spec_version.second);
}

int64_t end_value = spec_version.second + 1;
Expand Down Expand Up @@ -609,8 +611,9 @@ Status VersionGraph::capture_consistent_versions(const Version& spec_version,
}
cur_idx = next_idx;
} else {
return Status::InternalError("fail to find path in version_graph. spec_version: {}-{}",
spec_version.first, spec_version.second);
return Status::InternalError<false>(
"fail to find path in version_graph. spec_version: {}-{}", spec_version.first,
spec_version.second);
}
}

Expand Down

0 comments on commit 538817a

Please sign in to comment.