Wiki

Clone wiki

scheduler-cron / CronJob

CronJob

It is designed for execution using Cron

Options

  • cron - Cron string which specified with special format

    type: string

  • func - the function that will be executed

    type: function

    • returns: undefined

Methods

  • stop - stops function execution

    returns: undefined

How to use

var CronJob = require('scheduler-cron').CronJob;

new CronJob('0 5 * * * *', function() {
    // Uploading of my everyday server statistics in 05:00
});

Updated