incubator-allura-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From john...@apache.org
Subject git commit: [#4691] Flush after computing LCD for each commit
Date Fri, 07 Dec 2012 17:28:11 GMT
Updated Branches:
  refs/heads/cj/4691 6de80ffca -> 8744c48e3


[#4691] Flush after computing LCD for each commit

Signed-off-by: Cory Johns <johnsca@geek.net>


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

Branch: refs/heads/cj/4691
Commit: 8744c48e37d494fd932eefb3194e158d420469d2
Parents: 6de80ff
Author: Cory Johns <johnsca@geek.net>
Authored: Fri Dec 7 17:27:52 2012 +0000
Committer: Cory Johns <johnsca@geek.net>
Committed: Fri Dec 7 17:27:52 2012 +0000

----------------------------------------------------------------------
 Allura/allura/model/repo_refresh.py |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-allura/blob/8744c48e/Allura/allura/model/repo_refresh.py
----------------------------------------------------------------------
diff --git a/Allura/allura/model/repo_refresh.py b/Allura/allura/model/repo_refresh.py
index ea0154b..36ca927 100644
--- a/Allura/allura/model/repo_refresh.py
+++ b/Allura/allura/model/repo_refresh.py
@@ -11,7 +11,7 @@ import tg
 from pylons import g,c
 
 from ming.base import Object
-from ming.orm import mapper, session
+from ming.orm import mapper, session, ThreadLocalORMSession
 
 from allura.lib import utils
 from allura.lib import helpers as h
@@ -104,6 +104,7 @@ def refresh_repo(repo, all_commits=False, notify=True):
         for i, oid in enumerate(reversed(commit_ids)):
             ci = cache.get(Commit, dict(_id=oid))
             compute_lcds(ci, cache)
+            ThreadLocalORMSession.flush_all()
             if (i+1) % 100 == 0:
                 log.info('Compute last commit info %d: %s', (i+1), ci._id)
 


Mime
View raw message