Open mihacooper opened 6 years ago
Here my thoughts about a thread pool implementation. The library lacks two things: thread method, that returns thread id (like thread:get_id()
), and the atomic variables, which is critical to the performance wise applications, imo. Is there any chance to see them in the future?
(lua 5.3)
https://gist.github.com/devildevilson/bdce61d7ec66e590a31b23c2bf1b6e1c
Thanks for this work. I will read the poll implementation and give you feedback later. About your question:
thread:get_id()
is right. We should add it. I have created an issue #146.
We want to create a thread pool over out threads and channels. To do that we should perform research for proper implementation and API design.