Scheduler Program
One thing that I run into frequently in my programming life is the desire to schedule events. I like CFSCHEDULE, but by iteself it has a few limitations that I don't like. It is a bit limited in the intervals available and I have to have an HTTP page set up for it.
What I want is the ability to schedule a CFC method to be run directly from that CFC. Fortunately, Scheduler.cfc allows me to do just that. Scheduler.cfc itself still requires a scheduled task to run it. Scheduler.cfc also has the ability to report data about the scheduled tasks that it has run, but (as it is just a CFC) it doesn't have a UI to report that data.
The Scheduler program solves both of those. It is essentially a wrapper for Scheduler.cfc. When the program is installed (copying it to a folder after installing Neptune), it automatically creates a "/schedule.cfm" and creates a ColdFusion scheduled task to execute it every 15 minutes (you can, of course change that). It also creates a page that reports all of the scheduled tasks running on the system as well as how long they execute (in seconds) on average, as well as the ability to see details of every time that they have run.
This information can be invaluable if you are trouble-shooting a scheduled task.
The Scheduler program is, of course, not useful by itself but is certainly useful in conjunction with any program(s) that use the Scheduler.cfc component.
This is my third official release of a Neptune program (I meant to release one in March, but I got busy). I think Starter Cart is more useful on its own and makes a better example of a large Neptune program, but Scheduler (like Admins) is a nice, small example. It also has the distinction of being the first official release on Neptune Beta 2.
While we use Scheduler.cfc extensively, we have only deployed the Scheduler program itself on a few sites so far.
Which bring me to some specs that I hope to include for each Neptune program that I release.
Size | 19.2 K uncompressed (11 files across 3 folders) | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Exposure |
|
||||||||||||||
Supported CFML Engines |
|
Right now, the program produces only the following component variable:
- Application.Scheduler
Other than that, however, this example should be clean example of a Neptune program. Like any Neptune program, to install it simply drop it into your site and browse to the folder.
You can download the "Scheduler" program or check the box next to "Scheduler" when creating a site on SebGen.com.
This program is open source and free for any use.
There are no comments for this entry.
[Add Comment]