PhpRiot
News Archive
PhpRiot Newsletter
Your Email Address:

More information

Derick Rethans: Connection Handling with the MongoDB PHP driver

Note: This article was originally published at PHPDeveloper on 5 December 2012.
PHPDeveloper

Continuing on with his look at the newly released version of the MongoDB driver for PHP Derick Rethans has posted more detail about the advanced connection handling options this new driver version provides.

The 1.3 release series of the PHP MongoDB driver features a rewritten connection handling library. This is quite a large change and changes how the PHP driver deals with persistent connections and connection pooling.

He starts with an example of a v1.2 driver connection, how the connection is requested from a pool and how, based on the integration of a worker into the connection process, v1.3 handles the connection requests. He includes a bit about replica set connections and authentication connections, complete with PHP code examples showing them in practice.