MDL-50287 completion: Rename tasks to remove the word 'cron'
[moodle.git] / lib / db / tasks.php
CommitLineData
309ae892
DW
1<?php
2// This file is part of Moodle - http://moodle.org/
3//
4// Moodle is free software: you can redistribute it and/or modify
5// it under the terms of the GNU General Public License as published by
6// the Free Software Foundation, either version 3 of the License, or
7// (at your option) any later version.
8//
9// Moodle is distributed in the hope that it will be useful,
10// but WITHOUT ANY WARRANTY; without even the implied warranty of
11// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12// GNU General Public License for more details.
13//
14// You should have received a copy of the GNU General Public License
15// along with Moodle. If not, see <http://www.gnu.org/licenses/>.
16
17/**
18 * Definition of core scheduled tasks.
19 *
20 * The handlers defined on this file are processed and registered into
21 * the Moodle DB after any install or upgrade operation. All plugins
22 * support this.
23 *
24 * @package core
25 * @category task
26 * @copyright 2013 Damyon Wiese
27 * @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
28 */
29
30defined('MOODLE_INTERNAL') || die();
31
32/* List of handlers */
33
34$tasks = array(
35 array(
36 'classname' => 'core\task\session_cleanup_task',
37 'blocking' => 0,
38 'minute' => '*',
39 'hour' => '*',
40 'day' => '*',
41 'dayofweek' => '*',
42 'month' => '*'
43 ),
44 array(
45 'classname' => 'core\task\delete_unconfirmed_users_task',
46 'blocking' => 0,
47 'minute' => '0',
48 'hour' => '*',
49 'day' => '*',
50 'dayofweek' => '*',
51 'month' => '*'
52 ),
53 array(
54 'classname' => 'core\task\delete_incomplete_users_task',
55 'blocking' => 0,
56 'minute' => '5',
57 'hour' => '*',
58 'day' => '*',
59 'dayofweek' => '*',
60 'month' => '*'
61 ),
309ae892
DW
62 array(
63 'classname' => 'core\task\backup_cleanup_task',
64 'blocking' => 0,
65 'minute' => '10',
66 'hour' => '*',
67 'day' => '*',
68 'dayofweek' => '*',
69 'month' => '*'
70 ),
71 array(
72 'classname' => 'core\task\tag_cron_task',
73 'blocking' => 0,
74 'minute' => '20',
75 'hour' => '*',
76 'day' => '*',
77 'dayofweek' => '*',
78 'month' => '*'
79 ),
80 array(
81 'classname' => 'core\task\context_cleanup_task',
82 'blocking' => 0,
83 'minute' => '25',
84 'hour' => '*',
85 'day' => '*',
86 'dayofweek' => '*',
87 'month' => '*'
88 ),
89 array(
90 'classname' => 'core\task\cache_cleanup_task',
91 'blocking' => 0,
92 'minute' => '30',
93 'hour' => '*',
94 'day' => '*',
95 'dayofweek' => '*',
96 'month' => '*'
97 ),
98 array(
99 'classname' => 'core\task\messaging_cleanup_task',
100 'blocking' => 0,
101 'minute' => '35',
102 'hour' => '*',
103 'day' => '*',
104 'dayofweek' => '*',
105 'month' => '*'
106 ),
107 array(
108 'classname' => 'core\task\send_new_user_passwords_task',
109 'blocking' => 0,
110 'minute' => '*',
111 'hour' => '*',
112 'day' => '*',
113 'dayofweek' => '*',
114 'month' => '*'
115 ),
116 array(
117 'classname' => 'core\task\send_failed_login_notifications_task',
118 'blocking' => 0,
119 'minute' => '*',
120 'hour' => '*',
121 'day' => '*',
122 'dayofweek' => '*',
123 'month' => '*'
124 ),
125 array(
126 'classname' => 'core\task\create_contexts_task',
127 'blocking' => 1,
77df1778
SL
128 'minute' => '0',
129 'hour' => '0',
309ae892
DW
130 'day' => '*',
131 'dayofweek' => '*',
132 'month' => '*'
133 ),
134 array(
135 'classname' => 'core\task\legacy_plugin_cron_task',
136 'blocking' => 0,
137 'minute' => '*',
138 'hour' => '*',
139 'day' => '*',
140 'dayofweek' => '*',
141 'month' => '*'
142 ),
143 array(
144 'classname' => 'core\task\grade_cron_task',
145 'blocking' => 0,
146 'minute' => '*',
147 'hour' => '*',
148 'day' => '*',
149 'dayofweek' => '*',
150 'month' => '*'
151 ),
152 array(
153 'classname' => 'core\task\events_cron_task',
154 'blocking' => 0,
155 'minute' => '*',
156 'hour' => '*',
157 'day' => '*',
158 'dayofweek' => '*',
159 'month' => '*'
160 ),
161 array(
160ccd3d 162 'classname' => 'core\task\completion_regular_task',
309ae892
DW
163 'blocking' => 0,
164 'minute' => '*',
165 'hour' => '*',
166 'day' => '*',
167 'dayofweek' => '*',
168 'month' => '*'
169 ),
51e488ea 170 array(
160ccd3d 171 'classname' => 'core\task\completion_daily_task',
51e488ea
JW
172 'blocking' => 0,
173 'minute' => 'R',
174 'hour' => 'R',
175 'day' => '*',
176 'dayofweek' => '*',
177 'month' => '*'
178 ),
309ae892
DW
179 array(
180 'classname' => 'core\task\portfolio_cron_task',
181 'blocking' => 0,
182 'minute' => '*',
183 'hour' => '*',
184 'day' => '*',
185 'dayofweek' => '*',
186 'month' => '*'
187 ),
188 array(
189 'classname' => 'core\task\plagiarism_cron_task',
190 'blocking' => 0,
191 'minute' => '*',
192 'hour' => '*',
193 'day' => '*',
194 'dayofweek' => '*',
195 'month' => '*'
196 ),
197 array(
198 'classname' => 'core\task\calendar_cron_task',
199 'blocking' => 0,
200 'minute' => '*',
201 'hour' => '*',
202 'day' => '*',
203 'dayofweek' => '*',
204 'month' => '*'
205 ),
206 array(
207 'classname' => 'core\task\blog_cron_task',
208 'blocking' => 0,
209 'minute' => '*',
210 'hour' => '*',
211 'day' => '*',
212 'dayofweek' => '*',
213 'month' => '*'
214 ),
215 array(
216 'classname' => 'core\task\question_cron_task',
217 'blocking' => 0,
218 'minute' => '*',
219 'hour' => '*',
220 'day' => '*',
221 'dayofweek' => '*',
222 'month' => '*'
223 ),
224 array(
225 'classname' => 'core\task\registration_cron_task',
226 'blocking' => 0,
f47e4eb4
AD
227 'minute' => 'R',
228 'hour' => 'R',
309ae892 229 'day' => '*',
f47e4eb4 230 'dayofweek' => 'R',
309ae892
DW
231 'month' => '*'
232 ),
233 array(
234 'classname' => 'core\task\check_for_updates_task',
235 'blocking' => 0,
236 'minute' => '0',
237 'hour' => '*/2',
238 'day' => '*',
239 'dayofweek' => '*',
240 'month' => '*'
241 ),
242 array(
243 'classname' => 'core\task\cache_cron_task',
244 'blocking' => 0,
245 'minute' => '50',
246 'hour' => '*',
247 'day' => '*',
248 'dayofweek' => '*',
249 'month' => '*'
250 ),
251 array(
252 'classname' => 'core\task\automated_backup_task',
253 'blocking' => 0,
254 'minute' => '50',
255 'hour' => '*',
256 'day' => '*',
257 'dayofweek' => '*',
258 'month' => '*'
259 ),
260 array(
261 'classname' => 'core\task\badges_cron_task',
262 'blocking' => 0,
263 'minute' => '*/5',
264 'hour' => '*',
265 'day' => '*',
266 'dayofweek' => '*',
267 'month' => '*'
268 ),
269 array(
270 'classname' => 'core\task\file_temp_cleanup_task',
271 'blocking' => 0,
272 'minute' => '55',
273 'hour' => '*/6',
274 'day' => '*',
275 'dayofweek' => '*',
276 'month' => '*'
277 ),
278 array(
279 'classname' => 'core\task\file_trash_cleanup_task',
280 'blocking' => 0,
281 'minute' => '55',
282 'hour' => '*/6',
283 'day' => '*',
284 'dayofweek' => '*',
285 'month' => '*'
286 ),
287 array(
288 'classname' => 'core\task\stats_cron_task',
289 'blocking' => 0,
290 'minute' => '0',
291 'hour' => '*',
292 'day' => '*',
293 'dayofweek' => '*',
294 'month' => '*'
295 ),
296 array(
297 'classname' => 'core\task\password_reset_cleanup_task',
298 'blocking' => 0,
299 'minute' => '0',
300 'hour' => '*/6',
301 'day' => '*',
302 'dayofweek' => '*',
303 'month' => '*'
304 )
305);