Merge lp:~sinzui/launchpad/registry-cache-4 into lp:launchpad
Status: | Merged | ||||
---|---|---|---|---|---|
Approved by: | Brad Crittenden | ||||
Approved revision: | no longer in the source branch. | ||||
Merged at revision: | 11314 | ||||
Proposed branch: | lp:~sinzui/launchpad/registry-cache-4 | ||||
Merge into: | lp:launchpad | ||||
Diff against target: |
92 lines (+27/-9) 2 files modified
lib/lp/registry/browser/tests/test_milestone.py (+24/-6) lib/lp/registry/templates/milestone-index.pt (+3/-3) |
||||
To merge this branch: | bzr merge lp:~sinzui/launchpad/registry-cache-4 | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Brad Crittenden (community) | code | Approve | |
Review via email: mp+31998@code.launchpad.net |
Description of the change
This is my branch to remove caching from milestone pages.
lp:~sinzui/launchpad/registry-cache-3
Diff size: 93
Launchpad bug:
https:/
Test command: ./bin/test -vv -t test_milestone
Pre-
Target release: 10.08
Remove caching from milestone pages
-------
On Fri, 2010-08-06 at 10:07 +0300, Bjorn Tillenius wrote:
> I'd be interested in knowing this as well. I've always wondered
> whether
> the caching on the milestone list actually helps, and how it helps.
> Considering it's cache:private, it means that each user has its own
> cache, right? So it doesn't help when multiple people look at the page
> the first time. It only helps when the same person reloads the page
> multiple times. Now, which use cases exist for that, except for
> checking
> if something changed, usually after having modified bugs himself, or
> someone on IRC told him that they changed bugs? For the use case when
> the user knows something has changed, he will try to reload until he
> actually sees the changes, and is a really bad user experience.
This is a well thought argument. I think anonymous users are the only
ones who benefit from the cache. The page spends most of its time in
python formatting objects and anonymous users/bots do benefit from a
fast loading page.
Rules
-----
Change the cache rules in the milestone template to anonymous. Only anonymous
users see a cached page.
QA
--
Using two browsers, one logged in, the other not.
* View a milestone in both browsers.
* Visit a bug listed in the page in the logged browser
* Change the status or assignee of the bug in the logged browser
* Visit the milestone gain in the logged browser
* Verify you see the change.
* Reload the anonymous browser
* Verify it has not changed, it does not show the bug has changed.
Lint
----
Linting changed files:
lib/lp/
lib/lp/
Test
----
* lib/lp/
* Renamed an existing test to show it tests the anonymous condition
* Added a new test for the logged in condition
Implementation
--------------
* lib/lp/
* Changed the cache instructions to anonymous.