{"id":17873069,"url":"https://github.com/yigitest/thread_pool","last_synced_at":"2025-07-19T16:03:04.399Z","repository":{"id":92391774,"uuid":"78282946","full_name":"yigitest/thread_pool","owner":"yigitest","description":"C++ thread pool","archived":false,"fork":false,"pushed_at":"2017-01-11T06:24:20.000Z","size":73,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-08T14:09:35.714Z","etag":null,"topics":["cpp","cpp11","futures","single-header","thread-pool"],"latest_commit_sha":null,"homepage":null,"language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/yigitest.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-01-07T14:16:09.000Z","updated_at":"2022-09-28T07:48:29.000Z","dependencies_parsed_at":"2023-05-17T02:45:33.144Z","dependency_job_id":null,"html_url":"https://github.com/yigitest/thread_pool","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yigitest%2Fthread_pool","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yigitest%2Fthread_pool/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yigitest%2Fthread_pool/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/yigitest%2Fthread_pool/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/yigitest","download_url":"https://codeload.github.com/yigitest/thread_pool/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246911495,"owners_count":20853654,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cpp","cpp11","futures","single-header","thread-pool"],"created_at":"2024-10-28T10:57:11.752Z","updated_at":"2025-04-02T23:41:50.671Z","avatar_url":"https://github.com/yigitest.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ThreadPool\nSimple C++11 thread pool.\n\n## Setup / Usage\n\n```cpp\n\n#include \"thread_pool.h\"\n#include \u003ciostream\u003e\n\nclass ApplyFoo {\n\tpublic:\n\tint operator()(int answer) const {\n\t\treturn answer;\n\t}\n};\n\nint main (int argc, char * argv[]) {\n    // create thread pool with 2 threads.\n    tp::ThreadPool tp(2);\n\t\n    // enqueue and store future\n    auto result = tp.enqueue(ApplyFoo(), 42);\n\t\n    // get result from future\n    std::cout \u003c\u003c result.get() \u003c\u003c std::endl;\t\n}\n\n```\n\n## Running Tests With CMake\n\n```\nmkdir build\ncd build\ncmake .. \nmake\nmake test\n```\n\n## Known Issues and TODOs\n* ~~DONE an api call for waiting until all tasks done.~~\n* TODO work stealing.\n* TODO map/reduce.\n\n\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyigitest%2Fthread_pool","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fyigitest%2Fthread_pool","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyigitest%2Fthread_pool/lists"}