Browse Source

use New for entry point

master
maze 3 years ago
parent
commit
e6dd2cb137
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      pool.go

+ 2
- 2
pool.go View File

@ -23,9 +23,9 @@ type Pool struct {
closed uint32
}
// NewPool initialises a new Pool with a backlog of size and a maximum number
// New initialises a new Pool with a backlog of size and a maximum number
// of workers worker Go routines. The workers spawn on-demand.
func NewPool(size, workers int) *Pool {
func New(size, workers int) *Pool {
if size <= 0 {
size = DefaultPoolSize
}


Loading…
Cancel
Save