Scheduler Service application consists of two parts:
Most important scheduler properties are:
Main application screen shows table of your schedulers. Each table row represents scheduler.
Click "Add new scheduler" to display new scheduler form. Fill form fields:
Click "Ok" button if you're happy with your settings or click "Cancel" if you changed your mind.
After you create scheduler it's initially in disabled state.
Now it's time to setup URL that gets called by scheduler. You must make sure that script returns
auth code you can see in schedulers table. If you want to test Scheduler Service and don't want
to create real script, you can put a text file on your server and paste auth code in this file.
Agent will disable your scheduler if response will not match auth code.
After you've set up schedulers target URL, you can click "Enable" link in schedulers "Commands" and your scheduler will be configured.
For testing purposes there's possibility to execute given scheduler by clicking "Test" link in schedulers row. Application will fetch your url and update "last execution time" and "next execution time" for this scheduler. Test page will show first 256 bytes of response received, so you can check if URL is correct.
Agent is a long running process that periodically checks with main page if there are any URLs to be fetched.
For each URL agent executes GET request and fetches first 256 bytes of response. Your app can get "broken pipe" errors if response data is longer than 256, because agents don't try to fetch full response. Make sure your scheduler handler executes quickly and returns small amouts of data.
Response data must be exactly equal to scheduler's auth code.
Auth code is a randomly generated string of letters and numbers.
It's purpose is to prevent users from calling URLs they don't own.
URL you put in scheduler definition must return the auth code, or agent will disable scheduler.
You can later investigate why scheduler url didn't work and re-enable scheduler manually by clicking "Enable" link
in "Commands" column.
Agents check auth codes against first 256 bytes of response stipped from whitespace. Python pseudocode is:
r = urllib.urlopen(url)
t = r.read(256)
if t.strip() != secretcode:
disable_scheduler(owner, name)
Network problems do not cause scheduler to be disabled.
If your scheduler gets disabled by agent, you'll be able to check when and why it got disabled by clicking on "Disabled" link in "Is Enabled" column in schedulers listing.
Some limits are enforced to ensure service works reliably.
| Max schedulers per user account | 10 |
| Max scheduler executions per user account | 120 |
| Minimal scheduler interval | 900 seconds |