node-toobusy icon indicating copy to clipboard operation
node-toobusy copied to clipboard

No singleton

Open nherment opened this issue 11 years ago • 3 comments

It would be great if it was possible to create multiple toobusy instance, each with a different maxLag:

  var Toobusy = require('toobusy')

  var toobusy1 = new Toobusy()
  toobusy1.maxLag(20)

  var toobusy2 = new Toobusy()
  toobusy2.maxLag(100)

I'd like to use toobusy to manage multiple actions with different priorities.

Right now the workaround is to look at the lag value but that defeats the niceness of toobusy which returns a simple boolean.

nherment avatar Nov 19 '13 11:11 nherment

:+1: I like the idea of one toobusy instance handling HTTP traffic, and another, more aggressive instance handling worker queue task consumption.

tlhunter avatar Dec 02 '14 19:12 tlhunter

This repo was abandoned quite some time ago. If this is the behavior you want, here is a wrapper for toobusy (a js fork) that has a number of spiffy features.

https://github.com/godaddy/node-connect-qos

asilvas avatar Dec 02 '14 19:12 asilvas

Could you updated the README saying this repo is deprecated and link to the suggested module?

tlhunter avatar Dec 17 '14 08:12 tlhunter