Jeremy Mikola 49e09578b7 Valid read preference tag sets should always be documents
This function was originally implemented in PHPC-424, before we started preparing tag sets in PHPC-359 to ensure that they serialized as BSON documents. There is no longer any reason to allow array types here.
2016-12-12 19:31:46 -05:00
2016-08-31 14:51:43 -04:00
2016-12-12 19:31:45 -05:00
2014-06-20 14:50:40 -07:00
2015-12-16 10:22:58 +00:00
2014-12-19 16:43:52 -05:00
2016-12-07 12:26:07 -05:00

pecl/mongodb (MongoDB driver for PHP)

Build Status Coverage Status

This is the low-level PHP driver for MongoDB. The API is the same as the HHVM driver for MongoDB. The documentation for both of them is the same, and can be found at http://docs.php.net/manual/en/set.mongodb.php

The driver is written to be a bare bone layer to talk to MongoDB, and therefore misses many convenience features. Instead, these convenience methods have been split out into a layer written in PHP, the MongoDB Library. Using this library should be your preferred way of interacting with MongoDB.

Please note that the new HHVM and PHP drivers implement a different API from the legacy driver at http://pecl.php.net/package/mongo; therefore existing libraries that use the legacy driver (e.g. Doctrine MongoDB's ODM) will not work with the new drivers.

In the long run, we hope that userland packages will be built atop this driver to implement various APIs (e.g. a BC layer for the existing driver, new fluent interfaces), management utilities (for creating admin utilities and cluster management applications), and other interesting libraries.

Documentation

Installation

To build and install the driver:

$ pecl install mongodb
$ echo "extension=mongodb.so" >> `php --ini | grep "Loaded Configuration" | sed -e "s|.*:\s*||"`

We recommend using this extension in conjunction with our userland library, which is distributed as mongodb/mongodb for Composer.

Contributing

See CONTRIBUTING.md

S
Description
No description provided
Readme Apache-2.0 12 MiB
Languages
PHP 62.7%
C 32%
M4 4.1%
JavaScript 0.7%
Shell 0.3%
Other 0.2%