func NewPool(parentCtx context.Context, opts ...func(*option)) *pool {
	ctx, cancel := context.WithCancel(parentCtx)
	p := &pool{
		ctx:    ctx,
		cancel: cancel,
		option: option{recoverFunc: defaultRecoverGoroutine},
	}
	for _, opt := range opts {
		opt(&p.option)
	}
	return p
}
// NewPool creates a Pool.
NewPool creates a Pool.
// NewPool creates a Pool .
func NewPool(parentCtx context.Context, opts ...func(*option)) *pool {
	ctx, cancel := context.WithCancel(parentCtx)
	p := &pool{
		ctx:    ctx,
		cancel: cancel,
		option: option{recoverFunc: defaultRecoverGoroutine},
	}
	for _, opt := range opts {
		opt(&p.option)
	}
	return p
}
func NewPool ( parentCtx context . Context , opts ... func ( * option ) ) * pool { ctx , cancel := context . WithCancel ( parentCtx ) p := & pool { ctx : ctx , cancel : cancel , option : option { recoverFunc : defaultRecoverGoroutine } , } for _ , opt := range opts { opt ( & p . option ) } return p }
NewPool creates a Pool.
NewPool creates a Pool .