ConcurrencyPool
Interface
Source: packages/concurrency-utils/src/lib/concurrency-pool.ts:5
Properties
[concurrencyPoolTypeGuard]
[concurrencyPoolTypeGuard]:
never
Type guard to prevent anyone outside from this library from creating concurrency pools. Type casting can still circumvent this mechanism but that is unsound in itself anyway.
Source: packages/concurrency-utils/src/lib/concurrency-pool.ts:12
Methods
acquireToken()
acquireToken():
Promise
<ConcurrencyToken
>
Acquires a token from the pool. If there are no tokens left, i.e. pool is of size 3 and 3 token have been granted, then this method will wait until one is available again.
Source: packages/concurrency-utils/src/lib/concurrency-pool.ts:19
Returns
Promise
<ConcurrencyToken
>