1. mixedpower
  2. Untitled project
  3. pyAggr3g470r

Commits

Cédric Bonhomme  committed 2087361

MongoDB index on 'article_date' for each new collection.

  • Participants
  • Parent commits 30e76ea
  • Branches default

Comments (0)

Files changed (1)

File source/mongodb.py

View file
         Creates a new collection for a new feed.
         """
         collection = self.db[new_collection["feed_id"]]
-        #collection.create_index([("article_date", pymongo.DESCENDING)], {"unique":False, "sparse":False})
+        collection.create_index([("article_date", pymongo.DESCENDING)], {"unique":False, "sparse":False})
         collection.ensure_index('article_content', pymongo.ASCENDING)
         collection.insert(new_collection)