Releases: mongodb/mongo-php-driver
1.4.0beta1
The PHP team is happy to announce that version 1.4.0beta1 of the mongodb PHP extension is now available on PECL. This release adds support for new features in MongoDB 3.6.
Release Highlights
The executeBulkWrite()
, executeCommand()
, and executeQuery()
methods on the Manager and Server objects now accept an options array as their third argument. Previously, each method took a single, optional ReadPreference or WriteConcern object. The old signature is still supported for backwards compatibility.
New executeReadCommand()
, executeReadWriteCommand()
, and executeWriteCommand()
methods have been added to the Manager and Server objects. These new methods take an options array as their third argument and, in the absence of such options, will inherit the client's read concern and/or write concern (when applicable). This is in contrast to the original executeCommand()
method.
A MongoDB\Driver\Session
class has been introduced to support client sessions for MongoDB 3.6. All methods that communicate with the server (i.e. all "execute" methods) now accept a "session" option. Presently, this option may be used for facilitating causally consistent reads.
When connected to MongoDB 3.6, the driver can now automatically retry failed write operations due to a network error or replica set failover. This functionality can be enabled by setting the retryWrites
URI option to true
.
This release adds new classes for deprecated BSON types (DBPointer, Symbol, and Undefined), which will allow the driver to round-trip documents containing such types. Previously, the driver would throw an exception when it encountered a deprecated type.
This release upgrades our libbson and libmongoc dependencies to 1.9.0. Support for MongoDB 2.4 and earlier has been removed.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=19688
Documentation
Documentation is available on PHP.net:
http://php.net/set.mongodb
Note: documentation for new APIs in 1.4.0 is still in progress.
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-beta
or update with:
pecl upgrade mongodb-beta
Windows binaries are available on PECL:
http://pecl.php.net/package/mongodb
1.3.4
The PHP team is happy to announce that version 1.3.4 of the mongodb PHP extension is now available on PECL.
Release Highlights
This release fixes the reflection information reported for the UTCDateTime constructor.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=19428
Documentation
Documentation is available on PHP.net:
http://php.net/set.mongodb
Feedback
Any bugs or issues may be reported via the following form:
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.3.3
The PHP team is happy to announce that version 1.3.3 of the mongodb PHP extension is now available on PECL.
Release Highlights
This release upgrades our libbson and libmongoc dependencies to 1.8.2, which fixes a crash when constructing a MongoDB\Driver\Manager
object with SCRAM-SHA-1 authentication but without a username. Rather than crash, the driver now correctly throws an exception.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=19388
Documentation
Documentation is available on PHP.net:
http://php.net/set.mongodb
Feedback
Any bugs or issues may be reported via the following form:
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.3.2
The PHP team is happy to announce that version 1.3.2 of the mongodb PHP extension is now available on PECL.
Release Highlights
This release reverts behavior introduced in 1.3.0 to throw an exception when the driver encounters an unsupported BSON type (i.e. undefined, symbol, DBPointer).
The undefined, symbol, and DBPointer types have long been deprecated in the BSON specification and were also never fully supported in the legacy mongo
extension (e.g. undefined in BSON was converted to null
in PHP). In versions prior to 1.3.0, the mongodb
extension ignored any fields containing an undefined, symbol, or DBPointer value when converting BSON to PHP. With this release, such fields will once again be ignored; however, the driver will also log a warning to the debug log (accessible via mongodb.debug
) when it encounters one of these types.
We ultimately expect to introduce classes for the undefined, symbol, and DBPointer types in 1.4.0 (see: PHPC-1027), which will allow the driver to round-trip BSON documents without silently dropping fields that contain an undefined, symbol, or DBPointer type.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=19299
Documentation
Documentation is available on PHP.net:
http://php.net/set.mongodb
Feedback
Any bugs or issues may be reported via the following form:
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.3.1
The PHP team is happy to announce that version 1.3.1 of the mongodb PHP extension is now available on PECL.
Release Highlights
This release upgrades our libbson and libmongoc dependencies to 1.8.1, which fixes an issue with building the driver from some non-bash shells.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=18882
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.3.0
The PHP team is happy to announce that version 1.3.0 of the mongodb PHP extension is now available on PECL.
Release Highlights
The driver now provides an API for monitoring database commands, which complies with the Command Monitoring specification. This API exists within the MongoDB\Driver\Monitoring
namespace and is demonstrated in the Application Performance Monitoring (APM) tutorial.
New BSON functions have been introduced to support output formats defined in the Extended JSON specification:
The MongoDB\BSON\fromJSON()
function has been enhanced to parse canonical and relaxed extended JSON, in addition to the legacy format. The jsonSerialize()
method on BSON classes implementing JsonSerializable has not changed; those methods continue to return data in the legacy format.
The ObjectID class has been renamed to ObjectId. As class names in PHP are case-insensitive, this change may go unnoticed; however, users are encouraged to use the canonical spelling. The Timestamp class now has getIncrement()
and getTimestamp()
methods, which return 32-bit integers for each component. The Binary class now enforces a 16-byte data length for UUID subtypes 0x03
and 0x04
. All BSON type classes now implement a corresponding interface.
The ReadConcern and WriteConcern classes now have an isDefault()
method, which checks whether the object was constructed without any options. This is most useful for inspecting the objects returned by Manager::getReadConcern()
and Manager::getWriteConcern()
. The PHP library utilizes this method to decide whether a read concern or write concern should be omitted from a database command.
BulkWrite::insert()
will now always return the inserted document's ID. Previously, it only returned an ObjectId if generated by the driver. WriteResult::getUpsertedIds()
has been improved to support all BSON types. Previously, types that were neither an ObjectId nor an integer were ignored.
This release includes compatibility fixes for PHP 7.2 based on testing with PHP 7.2 RC2. Windows builds now support OpenSSL 1.1.x for PHP 7.1.2 and later. Support for PHP 5.4 has been removed.
This release upgrades our libbson and libmongoc dependencies to 1.8.0.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=17597
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 this release:
1.2.11
The PHP team is happy to announce that version 1.2.11 of the mongodb PHP extension is now available on PECL.
Release Highlights
This release allows Windows builds to support OpenSSL 1.1.x for PHP 7.1.2 and later.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=18781
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.3.0RC1
The PHP team is happy to announce that version 1.3.0RC1 of the mongodb PHP extension is now available on PECL.
Release Highlights
This release includes compatibility fixes for PHP 7.2, which were uncovered by testing against PHP 7.2 RC1. Windows builds now support OpenSSL 1.1.x for PHP 7.1.2 and later.
Support for PHP 5.4 has been removed.
The ObjectID class has been renamed to ObjectId. As class names in PHP are case-insensitive, this change may go unnoticed; however, users are encouraged to use the canonical spelling.
This release upgrades our libbson and libmongoc dependencies to 1.8.0.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=18798
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-beta
or update with:
pecl upgrade mongodb-beta
Windows binaries are available on PECL:
http://pecl.php.net/package/mongodb
1.2.10
The PHP team is happy to announce that version 1.2.10 of our new mongodb PHP extension is now available on PECL.
Release Highlights
This release includes compatibility fixes for PHP 7.2, which were uncovered by testing against PHP 7.2 RC1. This testing also revealed an outstanding bug where the driver might alter memory of the return value for Persistable::bsonSerialize()
.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=18724
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.3.0beta1
The PHP team is happy to announce that version 1.3.0beta1 of the mongodb PHP extension is now available on PECL.
Release Highlights
The driver now provides an API for monitoring database commands, which complies with the Command Monitoring specification. This API exists within the MongoDB\Driver\Monitoring
namespace and is demonstrated in the Application Performance Monitoring (APM) tutorial.
New BSON functions have been introduced to support output formats defined in the Extended JSON specification:
The MongoDB\BSON\fromJSON()
function has been enhanced to parse canonical and relaxed extended JSON, in addition to the legacy format. The jsonSerialize()
method on BSON classes implementing JsonSerializable has not changed; those methods continue to return data in the legacy format.
The Timestamp class now has getIncrement()
and getTimestamp()
methods, which return 32-bit integers for each component. The Binary class now enforces a 16-byte data length for UUID subtypes 0x03
and 0x04
. All BSON type classes now implement a corresponding interface.
The ReadConcern and WriteConcern classes now have an isDefault()
method, which checks whether the object was constructed without any options. This is most useful for inspecting the objects returned by Manager::getReadConcern()
and Manager::getWriteConcern()
. The PHP library utilizes this method to decide whether a read concern or write concern should be omitted from a database command.
BulkWrite::insert()
will now always return the inserted document's ID. Previously, it only returned an ObjectId if generated by the driver. WriteResult::getUpsertedIds()
has been improved to support all BSON types. Previously, types that were neither an ObjectId nor an integer were ignored.
This release upgrades our libbson and libmongoc dependencies to 1.7.0.
A complete list of resolved issues in this release may be found at:
https://jira.mongodb.org/secure/ReleaseNote.jspa?projectId=12484&version=18715
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-beta
or update with:
pecl upgrade mongodb-beta
Windows binaries are available on PECL:
http://pecl.php.net/package/mongodb
Thanks
Thanks for our community contributors for this release: