Development Guide
Cron Plugins
This feature is available for ILIAS 4.4.x+.
With cron plugins custom cron jobs can be added to the system. They will be listed with the default cron jobs in Administration > General Settings > Cron Jobs. Most - if not all - features of cron jobs should be supported for custom cron jobs, too.
Plugin Slot
The plugin slot is named "Cron Hook" (Administration > Plugins > Slots). The corresponding plugin target directory isCustomizing/global/plugins/Services/Cron/CronHook
.
The plugin base class must extend "ilCronHookPlugin" and implement 3 abstract methods.
1 | include_once("./Services/Cron/classes/class.ilCronHookPlugin.php"); |
getCronJobInstances()
has to return an array with instances of all cron jobs of the plugingetCronJobInstance($a_job_id)
has to return a single instance of the cron job with the given id
ilCronJob
, see Chapter "Cron" in this guide.Additional Comments
Only custom cron jobs of active plugins will be processed and are listed in the administration. Additional settings for custom cron jobs are supported, but database handling or other methods of persistence have to be done by the plugin itself.