thor-schedule

0.1.1 • Public • Published

Thor-Schedule

Schedule client for thorbuster service

Example

initialize

schedule = require('thor-schedule').initialize({
  req: 'tcp://localhost:5567'
  sub: 'tcp://localhost:5568'
  debug: true
})

schedule

schedule.schedule
  schedule: Date.now() + 1000
  callbackData: {msg: 'I will be back'}
  callback: (data) ->
    console.log data.msg
==> 'I will be back'

cancel

schedule.schedule
  schedule: Date.now() + 1000
  taskId: 'sometitle'
  callback: ->
    console.log 'You will never see this message'
 
schedule.cancel({taskId: 'sometitle'})

Licence

MIT

Readme

Keywords

none

Package Sidebar

Install

npm i thor-schedule

Weekly Downloads

1

Version

0.1.1

License

MIT

Last publish

Collaborators

  • sailxjx