VisibleRefFilter Avoid touching the database for drafts
This is an analogous problem to the one with search results fixed in Ie54b9e2d. VisibleRefFilter is a little trickier because it was using ChangeCache, which only returned Changes, not the reviewer set. Change SearchingChangeCacheImpl to cache a different value type and return ChangeDatas from its search method so we can use the cached ReviewerSet where appropriate. Unfortunately for the Reindex program we still need to support not having a SearchingChangeCacheImpl, which means we have a completely separate codepath for reading changes from the database. Change-Id: Ic432a8e48a2bafc8d142b84b25101d95ffb674b7
This commit is contained in:
@@ -879,7 +879,7 @@ public class RefControlTest {
|
||||
|
||||
return new ProjectControl(Collections.<AccountGroup.UUID> emptySet(),
|
||||
Collections.<AccountGroup.UUID> emptySet(), projectCache,
|
||||
sectionSorter, repoManager, changeControlFactory, null, null,
|
||||
sectionSorter, repoManager, null, changeControlFactory, null, null,
|
||||
canonicalWebUrl, new MockUser(name, memberOf), newProjectState(local));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user