There are inherent issues with task blocking which mean that it has
never worked properly. It is also very buggy and can lead to massive
performance issues with task processing.
It is almost impossible to deprecate this in a staged fashion because
various APIs use the methods and it is not possible to determine which
are API uses and which are other valid uses.
In reality there has been little-to-no uptake on the use of this feature
and it should just be removed.
This has been generated running the following Sniffs, all
them part of the Moodle's CodeSniffer standard:
- PSR12.Functions.ReturnTypeDeclaration
- PSR12.Functions.NullableTypeDeclaration
- moodle.Methods.MethodDeclarationSpacing
- Squiz.Whitespace.ScopeKeywordSpacing
All them are, exclusively, about correct spacing, so the changes
are, all them, only white space changes.
Only exceptions to the above are 3 changes what were setting the
return type in a new line, and, when that happens, the closing
parenthesis (bracket) has to go to the same line than the colon.
Extracted code from sync_users() into separate functions
in order to enable ad-hoc sheduling, and chunking.
Co-authored-by: David Woloszyn <david.woloszyn@moodle.com>
Before applying a preset, the settings are displayed and, in some cases,
the Current/New value columns were empty.
This patch fixes it and guarantees this information is updated properly
every time the set_value() method is called.
Sheduled tasks for syncing users with external sources for auth_ldap
and auth_cas. Using task is simplier than setting separate cron
job for running cli script. Task are disabled by default.