You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@allura.apache.org by tv...@apache.org on 2013/09/10 17:55:22 UTC
[26/39] git commit: [#6545] re-order app_config_id,
label index so it can be shared
[#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/28d8c31e
Tree: http://git-wip-us.apache.org/repos/asf/incubator-allura/tree/28d8c31e
Diff: http://git-wip-us.apache.org/repos/asf/incubator-allura/diff/28d8c31e
Branch: refs/heads/db/6545
Commit: 28d8c31ee0cfb67005d5f9ecc7c855df92e4cafc
Parents: 5445e84
Author: Dave Brondsema <db...@slashdotmedia.com>
Authored: Wed Sep 4 13:53:35 2013 +0000
Committer: Tim Van Steenburgh <tv...@gmail.com>
Committed: Tue Sep 10 14:31:47 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/28d8c31e/Allura/allura/model/artifact.py
----------------------------------------------------------------------
diff --git a/Allura/allura/model/artifact.py b/Allura/allura/model/artifact.py
index 3910cad..9f91c6b 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()