Extends: undici.Dispatcher
A pool of Client instances connected to the same upstream target.
Requests are not guaranteed to be dispatched in order of invocation.
Arguments:
- url
URL | string- It should only include the protocol, hostname, and port. - options
PoolOptions(optional)
Extends: ClientOptions
- factory
(origin: URL, opts: Object) => Dispatcher- Default:(origin, opts) => new Client(origin, opts) - connections
number | null(optional) - Default:null- The number ofClientinstances to create. When set tonull, thePoolinstance will create an unlimited amount ofClientinstances. - clientTtl
number | null(optional) - Default:null- The amount of time before aClientinstance is removed from thePooland closed. When set tonull,Clientinstances will not be removed or closed based on age.
Implements Client.closed
Implements Client.destroyed
Returns PoolStats instance for this pool.
Implements Dispatcher.close([callback]).
Implements Dispatcher.destroy([error, callback]).
See Dispatcher.connect(options[, callback]).
Implements Dispatcher.dispatch(options, handler).
See Dispatcher.pipeline(options, handler).
See Dispatcher.request(options [, callback]).
See Dispatcher.stream(options, factory[, callback]).
See Dispatcher.upgrade(options[, callback]).
See Dispatcher Event: 'connect'.