mirror of https://github.com/panjf2000/ants.git
remove unused imports
This commit is contained in:
parent
5ae6239a57
commit
93533b243b
5
ants.go
5
ants.go
|
@ -25,7 +25,6 @@ package ants
|
||||||
import (
|
import (
|
||||||
"errors"
|
"errors"
|
||||||
"math"
|
"math"
|
||||||
"runtime"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
@ -33,11 +32,11 @@ const (
|
||||||
DefaultPoolSize = math.MaxInt32
|
DefaultPoolSize = math.MaxInt32
|
||||||
|
|
||||||
// DefaultCleanIntervalTime is the interval time to clean up goroutines
|
// DefaultCleanIntervalTime is the interval time to clean up goroutines
|
||||||
DefaultCleanIntervalTime = 30
|
DefaultCleanIntervalTime = 10
|
||||||
)
|
)
|
||||||
|
|
||||||
// Init a instance pool when importing ants
|
// Init a instance pool when importing ants
|
||||||
var defaultPool, _ = NewPool(DefaultPoolSize, 10)
|
var defaultPool, _ = NewPool(DefaultPoolSize, DefaultCleanIntervalTime)
|
||||||
|
|
||||||
// Submit submit a task to pool
|
// Submit submit a task to pool
|
||||||
func Submit(task f) error {
|
func Submit(task f) error {
|
||||||
|
|
Loading…
Reference in New Issue