zclllyybb commented on code in PR #31692:
URL: https://github.com/apache/doris/pull/31692#discussion_r1512009543


##########
be/src/io/fs/benchmark/fs_benchmark_tool.cpp:
##########
@@ -115,10 +115,14 @@ int main(int argc, char** argv) {
 
     // init s3 write buffer pool
     std::unique_ptr<doris::ThreadPool> s3_file_upload_thread_pool;
-    static_cast<void>(doris::ThreadPoolBuilder("S3FileUploadThreadPool")
-                              .set_min_threads(num_cores)
-                              .set_max_threads(num_cores)
-                              .build(&s3_file_upload_thread_pool));
+    doris::Status st = doris::ThreadPoolBuilder("S3FileUploadThreadPool")
+                               .set_min_threads(num_cores)
+                               .set_max_threads(num_cores)
+                               .build(&s3_file_upload_thread_pool);
+    if (!st.ok()) {
+        std::cout << "init s3 write buffer pool failed" << std::endl;

Review Comment:
   change all `std::cout` like this to `std::cerr`



##########
be/src/olap/compaction.cpp:
##########
@@ -79,7 +79,10 @@ bool is_rowset_tidy(std::string& pre_max_key, const 
RowsetSharedPtr& rhs) {
     // check segment size
     auto* beta_rowset = reinterpret_cast<BetaRowset*>(rhs.get());
     std::vector<size_t> segments_size;
-    static_cast<void>(beta_rowset->get_segments_size(&segments_size));
+    Status status = beta_rowset->get_segments_size(&segments_size);

Review Comment:
   for usage like this, you can introduce a new marco like 
`RETURN_FALSE_IF_ERROR` to deal with them



-- 
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: commits-unsubscr...@doris.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to