Yifan Zhang has posted comments on this change. ( http://gerrit.cloudera.org:8080/18867 )
Change subject: [threadpool] Fix unsafe behaviour when SchedulerThread shutdown ...................................................................... Patch Set 17: (1 comment) http://gerrit.cloudera.org:8080/#/c/18867/16//COMMIT_MSG Commit Message: http://gerrit.cloudera.org:8080/#/c/18867/16//COMMIT_MSG@9 PS16, Line 9: When shutting down a thread pool with SchedulerThread, thread pool's variable : 'scheduler_' is deleted and set to nullptr, at the same time, if thread pool : token is not shutdown and a task is scheduled on the toke > There are 3 participants: Thanks for your clarification! I wonder if we can use the 'pool_status_' to check if new tasks can be scheduled, just like the usage in ThreadPool::DoSubmit: https://github.com/apache/kudu/blob/00e78f58978c6d4f00871eb8bd91c29327799c76/src/kudu/util/threadpool.cc#L532-L535. -- To view, visit http://gerrit.cloudera.org:8080/18867 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: I021422f7e51e1007c5bdbc877ab445f70ba12357 Gerrit-Change-Number: 18867 Gerrit-PatchSet: 17 Gerrit-Owner: Yuqi Du <[email protected]> Gerrit-Reviewer: Alexey Serbin <[email protected]> Gerrit-Reviewer: Kudu Jenkins (120) Gerrit-Reviewer: Tidy Bot (241) Gerrit-Reviewer: Yifan Zhang <[email protected]> Gerrit-Reviewer: Yingchun Lai <[email protected]> Gerrit-Reviewer: Yuqi Du <[email protected]> Gerrit-Comment-Date: Mon, 07 Nov 2022 09:39:09 +0000 Gerrit-HasComments: Yes
