incubator-allura-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From brond...@apache.org
Subject git commit: [#6347] update index hint to match the index change
Date Thu, 13 Jun 2013 22:20:52 GMT
Updated Branches:
  refs/heads/master b7a01fb20 -> 167fa54b6


[#6347] update index hint to match the index change


Project: http://git-wip-us.apache.org/repos/asf/incubator-allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-allura/commit/167fa54b
Tree: http://git-wip-us.apache.org/repos/asf/incubator-allura/tree/167fa54b
Diff: http://git-wip-us.apache.org/repos/asf/incubator-allura/diff/167fa54b

Branch: refs/heads/master
Commit: 167fa54b64e3c5bba75a2ac7034b973011735676
Parents: b7a01fb
Author: Dave Brondsema <dbrondsema@slashdotmedia.com>
Authored: Thu Jun 13 22:20:46 2013 +0000
Committer: Dave Brondsema <dbrondsema@slashdotmedia.com>
Committed: Thu Jun 13 22:20:46 2013 +0000

----------------------------------------------------------------------
 Allura/allura/model/discuss.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-allura/blob/167fa54b/Allura/allura/model/discuss.py
----------------------------------------------------------------------
diff --git a/Allura/allura/model/discuss.py b/Allura/allura/model/discuss.py
index b316d99..9728994 100644
--- a/Allura/allura/model/discuss.py
+++ b/Allura/allura/model/discuss.py
@@ -95,7 +95,7 @@ class Discussion(Artifact, ActivityObject):
                 discussion_id=self._id))\
             .sort('timestamp', pymongo.DESCENDING)\
             .limit(1)\
-            .hint([('discussion_id', pymongo.ASCENDING)])
+            .hint([('discussion_id', pymongo.ASCENDING), ('status', pymongo.ASCENDING)])
             # hint is to try to force the index to be used, since mongo wouldn't select it
sometimes
             # https://groups.google.com/forum/#!topic/mongodb-user/0TEqPfXxQU8
         return q.first()


Mime
View raw message