schedule.scheduledJobs
See original GitHub issueThe scheduledJobs member of node-schedule is not mentioned in the documentation and also has a problem if two schedules with identical titles are added:
var schedule = require('node-schedule');
var rule = new schedule.RecurrenceRule();
rule.second = 10;
var j1 = schedule.scheduleJob("sched1", rule, function() { console.log("hi there 1"); });
var j2 = schedule.scheduleJob("sched1", rule, function() { console.log("hi there 2"); });
schedule.scheduledJobs['sched1'].cancel() // j1 will continue to be invoked, but can't be accessed for cancelation
Issue Analytics
- State:
- Created 7 years ago
- Reactions:2
- Comments:15 (5 by maintainers)
Top Results From Across the Web
How to delete all schedules in node-schedule? - Stack Overflow
but I would like code to get all scheduled jobs and then loop through them to delete each one. I think the following...
Read more >How to use the node-schedule.scheduledJobs function in ...
To help you get started, we've selected a few node-schedule.scheduledJobs examples, based on popular ways it is used in public projects.
Read more >node-schedule - npm
Node Schedule is a flexible cron-like and not-cron-like job scheduler for Node.js. It allows you to schedule jobs (arbitrary functions) for ...
Read more >Register-ScheduledJob (PSScheduledJob) - PowerShell
The Register-ScheduledJob cmdlet creates scheduled jobs on the local computer. A scheduled job is a Windows PowerShell background job that can be started ......
Read more >Scheduled jobs - Product Documentation | ServiceNow
Scheduled Jobs are automated pieces of work that can be performed at a specific time or on a recurring schedule.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
ok, thanks. Will try to help.
Another issue is that job scheduled to run only once (i,e, Date-based Scheduling) is never removed from
scheduledJobs
.