Skip to content

sciolist/node-postorder

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Postorder

Minimal work queue in postgres.

Installation

npm install postorder

Producer usage

var client = require('postorder').create('pg://localhost/db');
client.send({ my: 'word' });

Consumer usage

var client = require('postorder').create('pg://localhost/db');
client.listen(function (err, msg) {
  if(err) throw err;
  console.log(msg.my); //> 'word'
});

// you can also use shift to only take a single work item.
client.shift(function (err, msg) { });

About

Minimal work queue in postgres.

Resources

Stars

Watchers

Forks

Packages

No packages published