摘要:
官方示例 package main import ( "fmt" "github.com/panjf2000/ants/v2" "sync" "sync/atomic" "time" ) var sum int32 func myFunc(i interface{}) { n := i.(int32 阅读全文
posted @ 2023-12-27 09:59
朝阳1
阅读(132)
评论(0)
推荐(0)
摘要:
package main import ( "fmt" "sync" ) type Task struct { f func() error } var wg sync.WaitGroup type Pool struct { //任务通道 JobQueue chan Task //worker通道 阅读全文
posted @ 2023-12-27 09:58
朝阳1
阅读(28)
评论(0)
推荐(0)

浙公网安备 33010602011771号