Skip to content

Commit

Permalink
fix comments
Browse files Browse the repository at this point in the history
Signed-off-by: silverbullet233 <[email protected]>
  • Loading branch information
silverbullet233 committed Feb 13, 2025
1 parent 9ca8ad7 commit fe6aecc
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion be/src/service/staros_worker.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,13 @@ uint64_t StarOSWorker::get_table_id(const ShardInfo& shard) {
DCHECK(false) << "tableId doesn't exist in shard properties";
return kUnknownTableId;
}
return std::stoull(properties.at("tableId"));
const auto& tableId = properties.at("tableId");
try {
return std::stoull(tableId);
} catch (const std::exception& e) {
DCHECK(false) << "failed to parse tableId: " << tableId << ", " << e.what();
return kUnknownTableId;
}
}

absl::Status StarOSWorker::add_shard(const ShardInfo& shard) {
Expand Down

0 comments on commit fe6aecc

Please sign in to comment.