MongoDB Index optimization when using text-search in the aggregation framework
问题 We are building a simplified version of a search engine on top of MongoDB. Sample data set { "_id" : 1, "dept" : "tech", "updDate": ISODate("2014-08-27T09:45:35Z"), "description" : "lime green computer" } { "_id" : 2, "dept" : "tech", "updDate": ISODate("2014-07-27T09:45:35Z"), "description" : "wireless red mouse" } { "_id" : 3, "dept" : "kitchen", "updDate": ISODate("2014-04-27T09:45:35Z"), "description" : "green placemat" } { "_id" : 4, "dept" : "kitchen", "updDate": ISODate("2014-05-27T09