https://github.com/golang-infrastructure/go-goroutine-pool
go的goroutine pool库,一般用于任务执行
https://github.com/golang-infrastructure/go-goroutine-pool
Last synced: 9 months ago
JSON representation
go的goroutine pool库,一般用于任务执行
- Host: GitHub
- URL: https://github.com/golang-infrastructure/go-goroutine-pool
- Owner: golang-infrastructure
- License: mit
- Created: 2022-09-22T14:30:41.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2023-06-05T17:02:30.000Z (over 2 years ago)
- Last Synced: 2025-01-18T16:11:06.491Z (11 months ago)
- Language: Go
- Size: 82 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Golang协程池(Goroutine Pool)
无需创建线程池,全局限制最大运行的协程数(根据内存自动调整)
## 空闲释放
## 任务模式
两种任务模式:
- 提交任务payload和worker,使用相同的worker运行不同的payload
- 忽略payload的概念,直接运行worker函数
## 兼容复杂任务场景,多个Pool自由搭建DAG
## 一个收缩的例子
# TODO
- 支持往当前池子增加任务