MDL-76617 store_mongodb: Adjust moodle to mongo-php-library to v1.15.0

The new library version should work without problems with older
php-mongodb extension versions:
- v1.15.0 (paired version, tested).
- v1.14.1 (tested)

But, in order to keep them paired, the requirements have been
raised to the extension v1.15.0. See:

https://www.mongodb.com/docs/drivers/php/#compatibility
This commit is contained in:
Eloy Lafuente (stronk7) 2022-12-10 10:45:20 +01:00
parent c5efd54971
commit 47435471ee
4 changed files with 7 additions and 6 deletions

View File

@ -158,7 +158,7 @@ class cachestore_mongodb extends cache_store implements cache_is_configurable {
* @return bool
*/
public static function are_requirements_met() {
return version_compare(phpversion('mongodb'), '1.14', 'ge');
return version_compare(phpversion('mongodb'), '1.15', 'ge');
}
/**

View File

@ -7,6 +7,7 @@ Import procedure:
- Copy all the files and folders from the folder mongodb/src in the cache/stores/mongodb/MongoDB directory.
- Copy the license file from the project root.
- Update thirdpartylibs.xml with the latest version.
- Check the minim php driver version in https://docs.mongodb.com/drivers/php#compatibility and change the value in the "are_requirements_met" method if necessary.
- Check the minim php driver version in https://docs.mongodb.com/drivers/php#compatibility and change the
value in the "are_requirements_met" method if necessary.
This version (1.13.1) requires PHP mongodb extension >= 1.14.0
This version (1.15.0) requires PHP mongodb extension >= 1.15.0

View File

@ -4,7 +4,7 @@
<location>MongoDB</location>
<name>MongoDB PHP Library</name>
<description>This library provides a high-level abstraction around the lower-level PHP driver, also known as the mongodb extension.</description>
<version>1.13.1</version>
<version>1.15.0</version>
<license>Apache</license>
<licenseversion>2.0</licenseversion>
<repository>https://github.com/mongodb/mongo-php-driver</repository>

View File

@ -24,6 +24,6 @@
defined('MOODLE_INTERNAL') || die;
$plugin->version = 2022112800; // The current module version (Date: YYYYMMDDXX).
$plugin->version = 2022121000; // The current module version (Date: YYYYMMDDXX).
$plugin->requires = 2022111800; // Requires this Moodle version.
$plugin->component = 'cachestore_mongodb'; // Full name of the plugin.
$plugin->component = 'cachestore_mongodb'; // Full name of the plugin.