From 84d6618ac28192db24ab7a409acd376acb92d6e3 Mon Sep 17 00:00:00 2001 From: Jeremy Mikola Date: Fri, 6 Jul 2012 15:05:41 +0000 Subject: [PATCH] Revise MongoCollection::ensureIndex() background option https://jira.mongodb.org/browse/PHP-393 git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@326493 c90b9560-bf6c-de11-be94-00142212c4b1 --- reference/mongo/mongocollection/ensureindex.xml | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/reference/mongo/mongocollection/ensureindex.xml b/reference/mongo/mongocollection/ensureindex.xml index c1e4240e4d..c73a030ce2 100644 --- a/reference/mongo/mongocollection/ensureindex.xml +++ b/reference/mongo/mongocollection/ensureindex.xml @@ -80,11 +80,20 @@ "background" - If you are using MongoDB version 1.3.2+, you can create indexes in the - background while other operations are taking place. By default, index - creation happens synchronously. If you specify &true; with this - option, index creation will be asynchronous. + By default, index creation is a blocking operation and will stop other + operations on the database from proceeding until completed. If you + specify &true; for this option, the index will be created in the + background while other operations are taking place. + + + Prior to MongoDB 2.1.0, the index build operation is not a background + build when it replicates to secondaries, irrespective of this option. + See + Building Indexes with Replica Sets + for more information. + +