allura-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kentontay...@apache.org
Subject [allura] branch master updated: [#8345] fix: flush these events immediately, since they are in an extension that may run after regular end-of-request flush
Date Thu, 23 Jan 2020 17:58:07 GMT
This is an automated email from the ASF dual-hosted git repository.

kentontaylor pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/allura.git


The following commit(s) were added to refs/heads/master by this push:
     new 1a525fd  [#8345] fix: flush these events immediately, since they are in an extension
that may run after regular end-of-request flush
1a525fd is described below

commit 1a525fd7339daa5fb5c3a1755512a8bad38f3934
Author: Dave Brondsema <dave@brondsema.net>
AuthorDate: Wed Jan 22 18:19:41 2020 -0500

    [#8345] fix: flush these events immediately, since they are in an extension that may run
after regular end-of-request flush
---
 Allura/allura/model/project.py | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/Allura/allura/model/project.py b/Allura/allura/model/project.py
index 5a6f896..dfdc0b5 100644
--- a/Allura/allura/model/project.py
+++ b/Allura/allura/model/project.py
@@ -105,13 +105,13 @@ class ProjectCategory(MappedClass):
 class TroveCategoryMapperExtension(MapperExtension):
 
     def after_insert(self, obj, state, sess):
-        g.post_event('trove_category_created', obj.trove_cat_id)
+        g.post_event('trove_category_created', obj.trove_cat_id, flush_immediately=True)
 
     def after_update(self, obj, state, sess):
-        g.post_event('trove_category_updated', obj.trove_cat_id)
+        g.post_event('trove_category_updated', obj.trove_cat_id, flush_immediately=True)
 
     def after_delete(self, obj, state, sess):
-        g.post_event('trove_category_deleted', obj.trove_cat_id)
+        g.post_event('trove_category_deleted', obj.trove_cat_id, flush_immediately=True)
 
 
 class TroveCategory(MappedClass):


Mime
View raw message