Releases: mongodb/mongo-php-driver
1.2.0alpha2
The PHP team is happy to announce that version 1.2.0alpha2 of our new mongodb PHP extension is now available on PECL.
Release Highlights
This is the second preview release for 1.2.0. 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 MongoDB\Driver\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).
This release changes the PHP serialization format (i.e. serialize()
) of our BSON type classes, which was necessary for compatibility with our HHVM driver. The BSON type classes previously used O-type serialization and implemented a __wakeup()
method. They now use C-type serialization, implement PHP's Serializable interface, and no longer provide a wakeup()
method. This change means that the driver will not be able to unserialize()
strings created by previous 1.2.0-alpha1 release, which introduced PHP serialization support.
A MongoDB\BSON\ObjectID::getTimestamp()
helper method has been introduced, which returns the 4-byte timestamp component of an ObjectID as an integer. The second $flags
parameter to the MongoDB\BSON\Regex
constructor is now optional and defaults to an empty string.
Lastly, this release also upgrades our libbson and libmongoc dependencies to 1.5.0-dev. 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=17506
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
1.2.0alpha1
The PHP team is happy to announce that version 1.2.0alpha1 of our new mongodb PHP extension is now available on PECL.
Release Highlights
This is the first preview release for 1.2.0. It contains a significant amount of internal refactoring to remove our dependence on libmongoc's private API, which is much awaited good news for users who install the driver through their OS package manager (e.g. CentOS, Debian). This release also upgrades our libbson and libmongoc dependencies to 1.4.0-beta1. The final 1.2.0 release will depend on libson and libmongoc 1.4.0.
Internal changes aside, we did manage to sneak a few new features into this release. BSON classes now support PHP serialization and var_export()
. JSON serialization is still not implemented, but we plan to have that ready for 1.2.0. 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.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=17200
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 not available for this release due to a build issue; however, they should be available for the next alpha or beta release.
Thanks
Thanks for our community contributors for 1.2.0alpha1:
1.1.8
The PHP team is happy to announce that version 1.1.8 of our new mongodb PHP extension is now available on PECL.
Release Highlights
Numerous users have reported an issue with the driver unnecessarily attempting to enable SSL on a persistent stream, which already had SSL enabled. This problem commonly manifested itself with "SSL/TLS already set-up for this stream" exceptions thrown on alternating requests to the same worker process. As a stop-gap solution, this release includes a patch to disable stream persistence for SSL connections. A more robust solution is being implemented in PHPC-605 and PHPC-433 for 1.2.0.
This release also fixes an issue with MongoDB\BSON\UTCDateTime::toDateTime()
where microseconds were not properly set on the returned DateTime object.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=17045
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
Thanks
Thanks for our community contributors for 1.1.8:
1.1.7
The PHP team is happy to announce that version 1.1.7 of our new mongodb PHP extension is now available on PECL.
Release Highlights
This release fixes a several use-after-free bugs related to SSL connections and using Cursor or Server objects after their originating Manager object has been unset. Additionally, the ObjectID constructor has been fixed to no longer alter the memory of its string argument.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=16808
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
Thanks
Thanks for our community contributors for 1.1.7:
1.1.6
The PHP team is happy to announce that version 1.1.6 of our new mongodb PHP extension is now available on PECL.
Release Highlights
This release fixes a bug with parsing the connectTimeoutMS
option, when passed through MongoDB\Driver\Manager
's options array. It also resolves an issue where BulkWrite::insert()
would not generate ObjectID (and return null) if another top-level field in the document had an "_id" prefix. In such a case, libmongoc would still generate an ObjectID for the document; however, that value would not be made available through the PHP driver.
This release also bumps the versions of bundled libmongoc and libbson libraries to 1.3.5.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=16611
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.5
The PHP team is happy to announce that version 1.1.5 of our new mongodb PHP extension is now available on PECL.
Release Highlights
This release fixes a segfault that several users had experienced running the driver and its bundled libmongoc library with FPM on Linux and OS X systems. The issue stemmed from libmongoc's shutdown function being invoked before the driver could unregister its memory allocation functions (typically those for Zend's memory manager). As a result, libmongoc might free certain resources with the wrong function and trigger a segfault.
Those running the driver without libmongoc bundled in (i.e. dynamically loading a system library) will need to wait for CDRIVER-1165 to be implemented and released upstream. For the time being, they may consider switching to a bundled build of the driver.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=16604
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
Thanks
Special thanks to Paul Buonopane for providing a thorough investigation of this issue in his bug report, which ultimately lead to the diagnosis and fix.
1.1.4
The PHP team is happy to announce that version 1.1.4 of our new mongodb PHP extension is now available on PECL.
Release Highlights
This release fixes a BSON encoding issue where 64-bit integer array keys would be truncated to 32-bit values. Additionally, the ObjectID constructor was improved to accept uppercase hexadecimal characters (it previously required lowercase strings).
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=16582
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.3
The PHP team is happy to announce that version 1.1.3 of our new mongodb PHP extension is now available on PECL.
Release Highlights
This release fixes a segfault when decoding corrupt BSON and improves error reporting when attempting to convert invalid BSON to a PHP variable or JSON string.
When serializing root and embedded Persistable objects, the resulting BSON document will now always include the class name identifier field (i.e. __pclass
). Previously, the driver only included the field when serializing objects for insertion or via fromPHP()
. This change makes the driver compliant with the existing Persistence specification; however, it may break existing code that returned atomic modifiers from Peristable::bsonSerialize()
to use with an update query.
There are several fixes related to handling of 64-bit integers, including but not limited to UTCDateTime's constructor accepting a numeric string on 32-bit platforms and the encoding and decoding of 64-bit integers to and from BSON.
Server selection failures now throw a ConnectionTimeoutException instead of a generic RuntimeException. This affects executeBulkWrite()
, executeCommand()
, executeQuery()
, and selectServer()
, which are the four driver methods that may result in server selection and/or connection initialization.
The WriteException message, which was previously "BulkWrite error", now includes a concatenation of all write and write concern errors.
The "readconcernlevel" option is now parsed from the Manager constructor's options array. Previously, it was only parsed from the connection URI string.
The ObjectID constructor no longer aborts when constructed with a null value. Instead, a new ObjectID will be generated, which is the same behavior as if no argument had been passed.
This release also bumps our libmongoc and libbson dependencies to 1.3.3. Notably, this update adds support for negative cursor limits (CDRIVER-1054).
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=16483
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.2
The PHP team is happy to announce that version 1.1.2 of our new mongodb PHP extension is now available on PECL.
Release Highlights
This release fixes a symbol collision that caused segfaults for some users who had both the new and legacy drivers (mongodb.so and mongo.so, respectively) loaded. Additionally, it resolves an issue with BSON encoding of variable references in PHP 7.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=16396
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
Thanks
Thanks for our community contributors for 1.1.2:
1.1.1
The PHP team is happy to announce that version 1.1.1 of our new mongodb PHP extension is now available on PECL. This release adds support for PHP 7, but is otherwise functionally equivalent to 1.1.0.
Release Highlights
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=16390
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
Thanks
Thanks for our community contributors for 1.1.1: