MDL-67594 core_lock: Deprecate supports_recursion()
This commit is contained in:
Vendored
+3
@@ -1,6 +1,9 @@
|
||||
This files describes API changes in /cache/stores/* - cache store plugins.
|
||||
Information provided here is intended especially for developers.
|
||||
|
||||
=== 4.0 ===
|
||||
* The function supports_recursion() from the lock_factory interface has been deprecated including the related implementations.
|
||||
|
||||
=== 3.9 ===
|
||||
* The record_cache_hit/miss/set methods now take a cache_store instead of a cache_definition object
|
||||
|
||||
|
||||
@@ -91,9 +91,13 @@ class db_record_lock_factory implements lock_factory {
|
||||
|
||||
/**
|
||||
* Multiple locks for the same resource can be held by a single process.
|
||||
*
|
||||
* @deprecated since Moodle 4.0.
|
||||
* @return boolean - False - not process specific.
|
||||
*/
|
||||
public function supports_recursion() {
|
||||
debugging('The function supports_recursion() is deprecated, please do not use it anymore.',
|
||||
DEBUG_DEVELOPER);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -108,9 +108,13 @@ class file_lock_factory implements lock_factory {
|
||||
|
||||
/**
|
||||
* Multiple locks for the same resource cannot be held from a single process.
|
||||
*
|
||||
* @deprecated since Moodle 4.0.
|
||||
* @return boolean - False
|
||||
*/
|
||||
public function supports_recursion() {
|
||||
debugging('The function supports_recursion() is deprecated, please do not use it anymore.',
|
||||
DEBUG_DEVELOPER);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -76,9 +76,12 @@ class installation_lock_factory implements lock_factory {
|
||||
/**
|
||||
* Multiple locks for the same resource cannot be held from a single process.
|
||||
*
|
||||
* @deprecated since Moodle 4.0.
|
||||
* @return boolean - False
|
||||
*/
|
||||
public function supports_recursion() {
|
||||
debugging('The function supports_recursion() is deprecated, please do not use it anymore.',
|
||||
DEBUG_DEVELOPER);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -63,6 +63,7 @@ interface lock_factory {
|
||||
/**
|
||||
* Supports recursion.
|
||||
*
|
||||
* @deprecated since Moodle 4.0.
|
||||
* @return boolean - True if attempting to get 2 locks on the same resource will "stack"
|
||||
*/
|
||||
public function supports_recursion();
|
||||
|
||||
@@ -106,9 +106,12 @@ class mysql_lock_factory implements lock_factory {
|
||||
* Hard coded to false and workaround inconsistent support in different
|
||||
* versions of MySQL / MariaDB.
|
||||
*
|
||||
* @deprecated since Moodle 4.0.
|
||||
* @return boolean - false
|
||||
*/
|
||||
public function supports_recursion() {
|
||||
debugging('The function supports_recursion() is deprecated, please do not use it anymore.',
|
||||
DEBUG_DEVELOPER);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -119,9 +119,13 @@ class postgres_lock_factory implements lock_factory {
|
||||
|
||||
/**
|
||||
* Multiple locks for the same resource can be held by a single process.
|
||||
*
|
||||
* @deprecated since Moodle 4.0.
|
||||
* @return boolean - Defer to the DB driver.
|
||||
*/
|
||||
public function supports_recursion() {
|
||||
debugging('The function supports_recursion() is deprecated, please do not use it anymore.',
|
||||
DEBUG_DEVELOPER);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user