= Quartz Scheduler = || '''Date''' || 2012/04/27 || || '''Contact(s)''' || [http://wiki.osgeo.org/wiki/User:Jeichar Jesse Eichar] || || '''Last edited''' || || || '''Status''' || draft || || '''Assigned to release''' || 2.8 || || '''Resources''' || R&D Camptocamp || || '''Code''' ||will be announced soon || || '''Ticket''' || #876 || == Overview == Replace the custom code for scheduling tasks, Lucene and harvesting to use the Quartz framework. === Proposal Type === * '''Type''': Modification * '''App''': !GeoNetwork * '''Module''': === Links === * '''Email discussions''': * '''IRC discussions''': === Voting History === * None as yet ---- == Motivations == Geonetwork uses custom code for scheduling harvesting tasks as well as for 'Schedule' tasks. I have experienced very difficult to debug cases where tasks are not executed correctly. In addition the Quartz framework has many more features and allows more advanced scheduling features like cron style scheduling, thread pooling, multiple schedules for a single task. Listeners for notification when tasks are executed. There are also options for distribution of tasks which could be useful when clustering Geonetwork. Right now there are 3 different implementations and all have fairly limited functionality. == Proposal == The existing API will be unchanged for Schedule, Lucene and Harvesters, only the implementation will change. Components of interest: * web/src/main/webapp/WEB-INF/classes/quartz.properties * properties for the default scheduler. This scheduler will be used if the tasks specific scheduler configurations do not exist * web/src/main/webapp/WEB-INF/classes/quartz-scheduleManager.properties.disabled * if the .disabled is removed then the scheduleManager will have a dedicated scheduler configured with the configuration in this file. Otherwise the default scheduler will be used * web/src/main/webapp/WEB-INF/classes/quartz-luceneOptimize.properties.disabled * if the .disabled is removed then the LuceneOptimization tasks will have a dedicated scheduler configured with the configuration in this file. Otherwise the default scheduler will be used * web/src/main/webapp/WEB-INF/classes/quartz-abstractHarvester.properties * The Harvester scheduler configuration file. If this file is deleted or renamed harvesting will use the default scheduler * jeeves/.../ScheduleJob.java * An adapter between the Quartz Job API and the Geonetwork Schedule API * jeeves/.../ScheduleListener.java * A listener that listens for Job to be executed and if the job is a ScheduleJob the Schedule object and the ScheduleContext will be set on the ScheduleJob for the execution. === Backwards Compatibility Issues === No compatibility issues == Risks == Nothing notable == Participants == * As above