Permalink
Browse files

#11147: `upgrade_environment()` synchronizes ticket attributes to tag…

…s table in order to reduce transactions in `TicketTagProvider._fetch_tkt_tags()` on first request
  • Loading branch information...
1 parent 7bba2e1 commit 15e64a5ff49dac312451ee9bad2469d933e90d3f @jun66j5 committed Oct 28, 2013
Showing with 5 additions and 0 deletions.
  1. +5 −0 tractags/db.py
View
@@ -12,6 +12,7 @@
from tractags import db_default
from tractags.api import _
+from tractags.ticket import TicketTagProvider
class TagSetup(Component):
@@ -75,6 +76,10 @@ def upgrade_environment(self, db):
""", (db_default.schema_version,))
self.log.info("Upgraded TracTags db schema from version %d to %d"
% (schema_ver, db_default.schema_version))
+
+ TicketTagProvider(self.env)._fetch_tkt_tags(db)
+ self.log.info("Synchronized ticket attributes to tags table")
+
db.commit()
# Internal methods

0 comments on commit 15e64a5

Please sign in to comment.