Hi everyone,
In the documentation, section "Sharding Introduction" (http://
www.mongodb.org/display/DOCS/Sharding+Introduction), we can read :
> db.foo.find(...).count() || type=Variable || comments=Same as the corresponding find() operation
> db.foo.count() || type=Global || commments=parallel
But, when I open the source code, in shell/collection.js, line 419, we
can read that db.coll.count() cals db.coll.find().count().
The fact that db.coll.count() is just a helper makes sense, but now I
don't understand the documentation.
db.find() is sequential right ? and so is db.find().count() ?
Finally, I'm wondering if writing my own map/reduce jobs for
count( criteria ) would give better performances when running on a
scaling architecture that the mongo's count() ?