1.1.2 • Published 8 years ago

pensi-scheduler v1.1.2

Weekly downloads
1
License
MIT
Repository
github
Last release
8 years ago

Pensi-Scheduler

Is a simple event manager for nodejs. You can create different periods to support many types of events and it only uses one setTimout. There is also support for adding meta data for each events.

Note: the period is arbitrary, but I have only tested for hourly and daily tasks.

Sample Usage:

var sched = require('pensi-scheduler');
	
var TICKS_TWO_SECS = 2 * 1000;

// create a scheduler with two seconds period.
var sm = sched.create({period: TICKS_TWO_SECS});	
sm.addTask('A', new Date(), {name : 'my task'}); // execute a minute from now.

sm.once('interval', function(task){
    console.log('Running Task', task.name, '...');
	sm.stop();
});

sm.start();

Build Status Code Climate

1.1.3

6 years ago

1.1.2

8 years ago

1.1.1

8 years ago

0.0.8

10 years ago

0.0.7

10 years ago

0.0.6

10 years ago

0.0.5

10 years ago

0.0.4

10 years ago

0.0.3

10 years ago

0.0.2

10 years ago

0.0.1

10 years ago