Merge lp:~stub/launchpad/bug-602936-hotbug-caching into lp:launchpad

Proposed by Stuart Bishop
Status: Merged
Approved by: Robert Collins
Approved revision: no longer in the source branch.
Merged at revision: 11302
Proposed branch: lp:~stub/launchpad/bug-602936-hotbug-caching
Merge into: lp:launchpad
Diff against target: 50 lines (+1/-21)
2 files modified
lib/lp/bugs/stories/bugs/xx-product-bugs-page.txt (+0/-18)
lib/lp/bugs/templates/bugtarget-bugs.pt (+1/-3)
To merge this branch: bzr merge lp:~stub/launchpad/bug-602936-hotbug-caching
Reviewer Review Type Date Requested Status
Robert Collins (community) Approve
Review via email: mp+31735@code.launchpad.net

Commit message

Turn off caching of the the 'hotbugs' list

Description of the change

Turn off caching the 'hotbugs' list as it annoys some people and likely isn't saving us much.

To post a comment you must log in.
Revision history for this message
Robert Collins (lifeless) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'lib/lp/bugs/stories/bugs/xx-product-bugs-page.txt'
2--- lib/lp/bugs/stories/bugs/xx-product-bugs-page.txt 2010-06-09 14:01:54 +0000
3+++ lib/lp/bugs/stories/bugs/xx-product-bugs-page.txt 2010-08-05 07:11:10 +0000
4@@ -153,11 +153,6 @@
5 For each bug we have the number, title, status, importance and the time
6 since the last update.
7
8-Note: since the hot bugs list is cached, we have to clear the cache first to
9-get the results we expect.
10-
11- >>> from canonical.testing.layers import MemcachedLayer
12- >>> MemcachedLayer.purge()
13 >>> anon_browser.open('http://bugs.launchpad.dev/firefox')
14 >>> print extract_text(
15 ... find_tag_by_id(anon_browser.contents, 'hot-bugs'))
16@@ -185,19 +180,6 @@
17 ... BugTaskStatus.FIXRELEASED, project_owner)
18 >>> logout()
19
20-The hot bugs list is cached to help page performance, so these changes are not
21-immediately visible.
22-
23- >>> 'cache:private 10 minute' in anon_browser.contents
24- True
25- >>> anon_browser.reload()
26- >>> 'Summary for new bug 3' in anon_browser.contents
27- True
28-
29-Once the cache has cleared, which we do manually here in the test,
30-the Fix Released bug, bug 18, is no longer shown.
31-
32- >>> MemcachedLayer.purge()
33 >>> anon_browser.reload()
34 >>> print extract_text(
35 ... find_tag_by_id(anon_browser.contents, 'hot-bugs'))
36
37=== modified file 'lib/lp/bugs/templates/bugtarget-bugs.pt'
38--- lib/lp/bugs/templates/bugtarget-bugs.pt 2010-06-15 19:37:37 +0000
39+++ lib/lp/bugs/templates/bugtarget-bugs.pt 2010-08-05 07:11:10 +0000
40@@ -107,9 +107,7 @@
41 --></script>
42 </tal:has_bugtasks>
43
44- <tal:has_hot_bugs condition="view/hot_bugs_info/bugtasks"
45- content="cache:private, 10 minute">
46- <!-- hot_bugs_info/bugtasks cache:private 10 minute -->
47+ <tal:has_hot_bugs condition="view/hot_bugs_info/bugtasks">
48 <h2>Hot bugs</h2>
49
50 <table class="listing" id="hot-bugs"