Releases: mongodb/mongo-php-driver
1.2.6
The PHP team is happy to announce that version 1.2.6 of our new mongodb PHP extension is now available on PECL.
Release Highlights
This release addresses two interrelated issues where forked child processes might re-use or destroy persisted libmongoc clients created by a parent process. Users are still advised not to share MongoDB\Driver\Manager
objects between threads and processes.
This release upgrades our libbson and libmongoc dependencies to 1.5.5, which fixes the localThresholdMS
URI option's default value and thus the behavior of read preference mode nearest
. Additionally, it fixes a crash after executing a query with a projection containing an empty string key.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=17962
Documentation
Documentation is available on PHP.net:
http://php.net/set.mongodb
Feedback
We would appreciate any feedback you might have on the project:
https://jira.mongodb.org/secure/CreateIssue.jspa?pid=12484&issuetype=6
Installation
You can either download and install the source manually, or you can install the extension with:
pecl install mongodb
or update with:
pecl upgrade mongodb
Windows binaries are available on PECL:
http://pecl.php.net/package/mongodb
1.2.5
The PHP team is happy to announce that version 1.2.5 of our new mongodb PHP extension is now available on PECL.
This release addresses a Windows build error and is otherwise functionally identical to 1.2.4.
Documentation
Documentation is available on PHP.net:
http://php.net/set.mongodb
Feedback
We would appreciate any feedback you might have on the project:
https://jira.mongodb.org/secure/CreateIssue.jspa?pid=12484&issuetype=6
Installation
You can either download and install the source manually, or you can install the extension with:
pecl install mongodb
or update with:
pecl upgrade mongodb
Windows binaries are available on PECL:
http://pecl.php.net/package/mongodb
1.2.4
The PHP team is happy to announce that version 1.2.4 of our new mongodb PHP extension is now available on PECL.
Release Highlights
This release fixes a memory leak in the BSON type classes, which was triggered during PHP's garbage collection. Additionally, it incorporates a bug fix from libmongoc where specifying a read concern for a query would lead to an error in the getMore
command issued during cursor iteration.
This release upgrades our libbson and libmongoc dependencies to 1.5.4.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=17921
Documentation
Documentation is available on PHP.net:
http://php.net/set.mongodb
Feedback
We would appreciate any feedback you might have on the project:
https://jira.mongodb.org/secure/CreateIssue.jspa?pid=12484&issuetype=6
Installation
You can either download and install the source manually, or you can install the extension with:
pecl install mongodb
or update with:
pecl upgrade mongodb
Windows binaries are available on PECL:
http://pecl.php.net/package/mongodb
1.2.3
The PHP team is happy to announce that version 1.2.3 of our new mongodb PHP extension is now available on PECL.
Release Highlights
On Windows platforms, the system CA store is now opened with a read-only flag. This resolves an issue for some Windows users where the driver was unable to properly verify the server's SSL certificate due to operating system permissions.
This release improves error reporting when the required JSON extension is missing. This should avoid the cryptic "undefined symbol" errors that users on some platforms (e.g. Debian, Red Hat) were encountering since the 1.2.0 release.
Several bug fixes for BSON encoding and decoding have been implemented, which enhance the driver's compliance with the BSON corpus specification test suite. Of note, PHPC-883 changes how BSON arrays types are decoded by disregarding each element's string keys and appending the elements to a PHP array in sequence. This ensure that the driver produces a packed PHP array (i.e. keys start at 0
and continue in sequence without gaps). Most users should not be affected by this change, as well-formed BSON uses sequential, numeric strings for such string keys.
Lastly, phpinfo()
output has been improved and will now show details about the SSL and SASL libraries in use.
This release upgrades our libbson and libmongoc dependencies to 1.5.3.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=17830
Documentation
Documentation is available on PHP.net:
http://php.net/set.mongodb
Feedback
We would appreciate any feedback you might have on the project:
https://jira.mongodb.org/secure/CreateIssue.jspa?pid=12484&issuetype=6
Installation
You can either download and install the source manually, or you can install the extension with:
pecl install mongodb
or update with:
pecl upgrade mongodb
Windows binaries are available on PECL:
http://pecl.php.net/package/mongodb
1.2.2
The PHP team is happy to announce that version 1.2.2 of our new mongodb PHP extension is now available on PECL.
Release Highlights
This release fixes a few bugs responsible for memory leaks and crashes.
For ZTS users (e.g. Apache), we resolved a crash due to initializing the persistent connection HashTable when the extension is first loaded. For OPcache users, we resolved a possible crash when constructing a MongoDB\Driver\Manager
or MongoDB\Driver\ReadPreference
with tag sets. On a related note, we addressed a bug where arguments passed to MongoDB\Driver\Manager
or MongoDB\Driver\ReadPreference
constructors might be changed.
MongoDB\Driver\Cursor::setTypeMap()
no longer leaks the cursor's current element if called during iteration. When setTypeMap()
is invoked, it will now free the current element and apply the new type map immediately. Previously, a new type map would only apply to the next element(s). This change does not affect users iterating a cursor with foreach
; however, it will be evident if the cursor is decorated with an IteratorIterator and the iteration methods are invoked directly.
Lastly, this fixes an issue with the Windows build script that prevent the libmongoc and libbson version numbers from being properly reported by phpinfo()
.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=17801
Documentation
Documentation is available on PHP.net:
http://php.net/set.mongodb
Feedback
We would appreciate any feedback you might have on the project:
https://jira.mongodb.org/secure/CreateIssue.jspa?pid=12484&issuetype=6
Installation
You can either download and install the source manually, or you can install the extension with:
pecl install mongodb
or update with:
pecl upgrade mongodb
Windows binaries are available on PECL:
http://pecl.php.net/package/mongodb
1.2.1
The PHP team is happy to announce that version 1.2.1 of our new mongodb PHP extension is now available on PECL.
Release Highlights
This release fixes two critical issues related to BSON encoding of immutable arrays, which may be created by PHP7's OPcache extension, and arrays or objects containing circular references.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=17725
Documentation
Documentation is available on PHP.net:
http://php.net/set.mongodb
Feedback
We would appreciate any feedback you might have on the project:
https://jira.mongodb.org/secure/CreateIssue.jspa?pid=12484&issuetype=6
Installation
You can either download and install the source manually, or you can install the extension with:
pecl install mongodb
or update with:
pecl upgrade mongodb
Windows binaries are available on PECL:
http://pecl.php.net/package/mongodb
1.1.10
The PHP team is happy to announce that version 1.1.10 of our new mongodb PHP extension is now available on PECL.
Release Highlights
This release fixes two critical issues related to BSON encoding of immutable arrays, which may be created by PHP7's OPcache extension, and arrays or objects containing circular references.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=17789
Documentation
Documentation is available on PHP.net:
http://php.net/set.mongodb
Feedback
We would appreciate any feedback you might have on the project:
https://jira.mongodb.org/secure/CreateIssue.jspa?pid=12484&issuetype=6
Installation
You can either download and install the source manually, or you can install the extension with:
pecl install mongodb
or update with:
pecl upgrade mongodb
Windows binaries are available on PECL:
http://pecl.php.net/package/mongodb
1.2.0
The PHP team is happy to announce that version 1.2.0 of our new mongodb PHP extension is now available on PECL. This release adds support for new features in MongoDB 3.4.
Release Highlights
This release supports new features of MongoDB 3.4, such as collation, the Decimal128 BSON type, and the handshake protocol to assist with server-side connection debugging.
It contains a significant amount of internal refactoring to remove our dependence on libmongoc's private API, which is good news for users who install the driver through their OS package manager (e.g. CentOS, Debian).
This release includes two significant changes related to how the driver communicates with a server and persists connections across requests (within a PHP worker process). Integration with PHP's streams API has been removed and the driver now relies on libmongoc for all socket communication, which should resolve some issues with connection and socket timeouts not being correctly applied. While previous versions of the driver persisted individual sockets across requests (based on host, port, and URI string), the driver now persists the entire libmongoc client object and its sockets (based on Manager constructor arguments). This means that SSL sessions and topology states will now be preserved across requests (i.e. the driver will not issue a flurry of isMaster commands to re-discover the topology on each request). See Connection Handling in the driver documentation for more information.
Internal changes aside, this release also includes a number of usability improvements. All BSON classes now support PHP serialization via serialize()
, JSON serialization via json_encode()
and PHP's JsonSerializable interface, and var_export()
.
The UTCDateTime constructor now defaults to the current time if no argument is provided and can also accept a DateTimeInterface instance.
The Binary and Javascript types now have __toString()
methods that return their binary data and code strings, respectively. The JavaScript class also has new getCode()
and getScope()
methods, which were curiously absent in previous versions.
The ObjectID class now has a getTimestamp()
helper method, which returns the 4-byte timestamp component of an ObjectID as an integer.
The Regex constructor's second $flags
parameter is now optional and defaults to an empty string. Flags are now sorted alphabetically when a Regex is constructed.
The Query constructor, BulkWrite::update()
, and BulkWrite::delete()
now accept a "collation" document option, which can be used to specify a locale-aware string comparison or sort order. See Collation in the MongoDB manual for additional information.
Read preferences now support a "maxStalenessSeconds" integer option, which can be used with modes other than "primary" to specify an acceptable replication delay for secondary servers (see: SERVER-12861). The "maxStalenessSeconds" option may also be used in the connection URI or options array provided to the Manager constructor to configure the default read preference.
This release upgrades our libbson and libmongoc dependencies to 1.5.0.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=16193
Documentation
Documentation is available on PHP.net:
http://php.net/set.mongodb
Feedback
We would appreciate any feedback you might have on the project:
https://jira.mongodb.org/secure/CreateIssue.jspa?pid=12484&issuetype=6
Installation
You can either download and install the source manually, or you can install the extension with:
pecl install mongodb
or update with:
pecl upgrade mongodb
Windows binaries are available on PECL:
http://pecl.php.net/package/mongodb
1.1.9
The PHP team is happy to announce that version 1.1.9 of our new mongodb PHP extension is now available on PECL.
Release Highlights
This maintenance release upgrades the bundled libmongoc package to 1.3.6, which primarily fixes a bug with spurious sockets timeouts (CDRIVER-1682, back-ported from CDRIVER-1571). The bug result in an unexpected ConnectionTimeoutException ("No suitable servers found") when one or more servers in a replica set were inaccessible, although other accessible servers should have been able to fulfill the server selection. This release also fixes a smaller bug where libmongoc swapped "connection timeout" and "connection error" messages, which are often included in the aforementioned ConnectionTimeoutException (CDRIVER-1683, back-ported from CDRIVER-1567).
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=17625
Documentation
Documentation is available on PHP.net:
http://php.net/set.mongodb
Feedback
We would appreciate any feedback you might have on the project:
https://jira.mongodb.org/secure/CreateIssue.jspa?pid=12484&issuetype=6
Installation
You can either download and install the source manually, or you can install the extension with:
pecl install mongodb
or update with:
pecl upgrade mongodb
Windows binaries are available on PECL:
http://pecl.php.net/package/mongodb
1.2.0alpha3
The PHP team is happy to announce that version 1.2.0alpha3 of our new mongodb PHP extension is now available on PECL.
Release Highlights
This is the third preview release for 1.2.0 and resolves a handful of outstanding issues for MongoDB 3.4 compatibility.
MongoDB\Driver\Query
, MongoDB\Driver\BulkWrite::update()
, and MongoDB\Driver\BulkWrite::delete()
now accept a "collation" document option, which can be used to specify a locale-aware string comparison or sort order (see: SERVER-1920 for additional information). MongoDB\Driver\ReadPreference
now supports a "maxStalenessMS" integer option, which can be used with modes other than "primary" to specify an acceptable replication delay for secondary servers (see: SERVER-12861). The "maxStalenessMS" option may also be used in the connection URI or options array provided to MongoDB\Driver\Manager
to configure the default read preference.
This release upgrades our libbson and libmongoc dependencies to 1.5.0-rc0. The final 1.2.0 release is expected to depend on libson and libmongoc 1.5.0.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=17532
Documentation
Documentation is available on PHP.net:
http://php.net/set.mongodb
Feedback
We would appreciate any feedback you might have on the project:
https://jira.mongodb.org/secure/CreateIssue.jspa?pid=12484&issuetype=6
Installation
You can either download and install the source manually, or you can install the extension with:
pecl install mongodb-alpha
or update with:
pecl upgrade mongodb-alpha
Windows binaries are available on PECL:
http://pecl.php.net/package/mongodb