PHP 7.2.0 Alpha 2 Released

MongoDB driver

Unlike the mongo extension, this extension supports both PHP and HHVM and is developed atop the » libmongoc and » libbson libraries. It provides a minimal API for core driver functionality: commands, queries, writes, connection management, and BSON serialization.

Userland PHP libraries that depend on this extension may provide higher level APIs, such as query builders, individual command helper methods, and GridFS. Application developers should consider using this extension in conjunction with the » MongoDB PHP library, which implements the same higher level APIs found in MongoDB drivers for other languages. This separation of concerns allows the driver to focus on essential features for which an extension implementation is paramount for performance.

add a note add a note

User Contributed Notes 2 notes

n dot vandermeij at mycademy dot com
6 months ago
*** ONLY FOR VERSIONS >= 1.2.0 ***

If you encounter the following error:

"PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/lib64/php/modules/'
- /usr/lib64/php/modules/ undefined symbol: php_json_serializable_ce in Unknown on line 0"

For a detailed explanation, please visit:

TLDR: You need to load the extension after the

Special thanks to Derick Rethans for pointing this out!
mike at eastghost dot com
17 days ago
There is an adapter - so old MongoClient / MongoDB code will run on the new PHP7/Mongo mess
To Top