The PHP team is happy to announce that version 1.16.0 of the mongodb PHP extension is now available on PECL. This release introduces support for MongoDB 7.0.
Release Highlights
This release introduces a backwards breaking change to the Queryable Encryption protocol. Using Queryable Encryption now requires MongoDB 7.0 or later.
MongoDB\BSON\Document and MongoDB\BSON\PackedArray classes have been introduced, which represent raw BSON data for documents and arrays, respectively. These classes can be instantiated via factory methods or by specifying bson
in a type map. Iterating a Document or PackedArray will yield a MongoDB\BSON\Iterator object.
Several improvements were made to MongoDB\BSON\Int64. The class constructor has been made public and Int64 objects now support casting, comparison, and arithmetic operations. Int64 objects always encode as a 64-bit integer in BSON, so this change will allow applications more control over BSON encoding. There is no change to the driver's default BSON decoding behavior; however, the new Document and PackedArray classes will always return 64-bit BSON integers as Int64 objects.
This release upgrades our libbson and libmongoc dependencies to 1.24.1. The libmongocrypt dependency has been upgraded to 1.8.1.
A complete list of resolved issues in this release may be found in JIRA.
Documentation
Documentation is available on PHP.net.
Installation
You can either download and install the source manually, or you can install the extension with:
pecl install mongodb-1.16.0
or update with:
pecl upgrade mongodb-1.16.0
Windows binaries are attached to the GitHub release notes.