parallel-throttle

1.0.1 • Public • Published

Parallel Throttle

Throttle async task with parallel limitation.

Deprecation

This package is deprecated to prefer the new runs-limit-func package.

Installation

npm i parallel-throttle

Usage

const ParallelThrottle = require('parallel-throttle')

// every task is an async function without any argument
const tasks = [...]

const throttle = new ParallelThrottle({maxTasksInParallel: 100})

tasks.forEach(task => {
  throttle.add(task).then(...).catch(...)
})

License

MIT

Package Sidebar

Install

npm i parallel-throttle

Weekly Downloads

0

Version

1.0.1

License

MIT

Unpacked Size

1.73 kB

Total Files

3

Last publish

Collaborators

  • zhaoyao91