🚀 Launch Week Day 3:Introducing Supply Chain Attack Campaigns Tracking.Learn More →
Socket
Book a DemoInstallSign in
Socket

level-mutex-batch

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

level-mutex-batch

Make sure only one leveldb batch is running at the time

latest
Source
npmnpm
Version
1.0.0
Version published
Maintainers
1
Created
Source

level-mutex-batch

Make sure only one leveldb batch is running at the time

npm install level-mutex-batch

build status

Usage

var lmbatch = require('level-mutex-batch')
var batch = lmbatch(db) // db is a levelup

batch([{type:'put', key:'hello', value:'world-1'}], function() {
  ...
})

batch([{type:'put', key:'hello', value:'world-2'}], function() {
  ...
})

batch([{type:'put', key:'hello', value:'world-3'}], function() {
  ...
})

The above example is guaranteed to always produce world-3 as the end result

License

MIT

FAQs

Package last updated on 15 Nov 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts