mirror of
https://gitee.com/johng/gf
synced 2026-06-06 16:21:40 +08:00
gpool updates
This commit is contained in:
@ -13,7 +13,7 @@ import (
|
||||
"sync"
|
||||
)
|
||||
|
||||
var pool = New(99999999)
|
||||
var pool = New(99999999, nil)
|
||||
var syncp = sync.Pool{}
|
||||
|
||||
func BenchmarkGPoolPut(b *testing.B) {
|
||||
|
||||
@ -10,7 +10,7 @@ func main() {
|
||||
interval := time.Second
|
||||
gtimer.AddSingleton(interval, func() {
|
||||
glog.Println("doing")
|
||||
time.Sleep(2*time.Second)
|
||||
time.Sleep(5*time.Second)
|
||||
})
|
||||
|
||||
select { }
|
||||
|
||||
Reference in New Issue
Block a user