Big update!Announcing Socket for GitHub 1.0. Learn more
Socket
BlogLoveFAQ
Install
Log in

batch

Package Overview
Dependencies
0
Maintainers
2
Versions
17
Issues
File Explorer

Advanced tools

batch

Simple async batch with concurrency control and progress reporting.

    0.6.1latest

Version published
Maintainers
2
Weekly downloads
11,447,968
decreased by-3.64%

Weekly downloads

Readme

Source

batch

Simple async batch with concurrency control and progress reporting.

Installation

$ npm install batch

API

var Batch = require('batch') , batch = new Batch; batch.concurrency(4); ids.forEach(function(id){ batch.push(function(done){ User.get(id, done); }); }); batch.on('progress', function(e){ }); batch.end(function(err, users){ });

Progress events

Contain the "job" index, response value, duration information, and completion data.

{ index: 1, value: 'bar', pending: 2, total: 3, complete: 2, percent: 66, start: Thu Oct 04 2012 12:25:53 GMT-0700 (PDT), end: Thu Oct 04 2012 12:25:53 GMT-0700 (PDT), duration: 0 }

License

MIT

FAQs

What is batch?

Simple async batch with concurrency control and progress reporting.

Is batch popular?

The npm package batch receives a total of 9,182,213 weekly downloads. As such, batch popularity was classified as popular.

Is batch well maintained?

We found that batch demonstrated a not healthy version release cadence and project activity. It has 2 open source maintainers collaborating on the project.

Last updated on 16 May 2017
Socket

Product

Subscribe to our newsletter

Get open source security insights delivered straight into your inbox. Be the first to learn about new features and product updates.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc