westonpace commented on a change in pull request #10233:
URL: https://github.com/apache/arrow/pull/10233#discussion_r625375258



##########
File path: cpp/src/arrow/util/future.h
##########
@@ -573,6 +573,15 @@ class ARROW_MUST_USE_TYPE Future {
   FRIEND_TEST(FutureRefTest, HeadRemoved);
 };
 
+namespace internal {

Review comment:
       I don't see this used.  What is the intent?  There is already 
`Future<T>::status`

##########
File path: cpp/src/arrow/util/thread_pool.cc
##########
@@ -321,13 +321,28 @@ void ThreadPool::CollectFinishedWorkersUnlocked() {
   state_->finished_workers_.clear();
 }
 
+thread_local ThreadPool* g_current_thread_pool = nullptr;
+
+ThreadPool* ThreadPool::GetCurrentThreadPool() { return g_current_thread_pool; 
}
+
+thread_local int g_current_thread_id = 0;
+
+int ThreadPool::GetCurrentThreadId() { return g_current_thread_id; }

Review comment:
       If this is returning the thread's `index` maybe `id` is not the best 
name?  Especially since it might be confused with the existing concept of a 
thread id.




-- 
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]


Reply via email to