allura-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From brond...@apache.org
Subject [01/10] git commit: [#6545] re-order app_config_id, label index so it can be shared
Date Fri, 06 Sep 2013 21:05:39 GMT
Updated Branches:
  refs/heads/db/6545 [created] 531d571de


[#6545] re-order app_config_id,label index so it can be shared

..shared with the main app_config_id index.  It was added in 1fc1d377
for faster ticket label lookup, but the order doesn't matter, so
better to share the first part of the index.


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

Branch: refs/heads/db/6545
Commit: 2501fb49a0466be98b5906dc30164031810cefa8
Parents: 56043b1
Author: Dave Brondsema <dbrondsema@slashdotmedia.com>
Authored: Wed Sep 4 13:53:35 2013 +0000
Committer: Dave Brondsema <dbrondsema@slashdotmedia.com>
Committed: Fri Sep 6 15:47:57 2013 +0000

----------------------------------------------------------------------
 Allura/allura/model/artifact.py | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-allura/blob/2501fb49/Allura/allura/model/artifact.py
----------------------------------------------------------------------
diff --git a/Allura/allura/model/artifact.py b/Allura/allura/model/artifact.py
index 294c3d0..31fb78a 100644
--- a/Allura/allura/model/artifact.py
+++ b/Allura/allura/model/artifact.py
@@ -61,7 +61,9 @@ class Artifact(MappedClass):
     class __mongometa__:
         session = artifact_orm_session
         name='artifact'
-        indexes = [ 'app_config_id', ('labels', 'app_config_id') ]
+        indexes = [
+            ('app_config_id', 'label'),
+        ]
         def before_save(data):
             if not getattr(artifact_orm_session._get(), 'skip_mod_date', False):
                 data['mod_date'] = datetime.utcnow()


Mime
View raw message