r81038 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r81037‎ | r81038 | r81039 >
Date:17:27, 26 January 2011
Author:reedy
Status:ok
Tags:
Comment:
(bug 23720) CodeReview doesn't show ancient revisions for a path

Fixed up path search limitation (missed from r793381)

Kill off $wgCodeReviewPathSearchHorizon too
Modified paths:
  • /trunk/extensions/CodeReview/CodeReview.php (modified) (history)
  • /trunk/extensions/CodeReview/backend/CodeRepository.php (modified) (history)
  • /trunk/extensions/CodeReview/ui/CodeRevisionListView.php (modified) (history)

Diff [purge]

Index: trunk/extensions/CodeReview/CodeReview.php
@@ -182,12 +182,6 @@
183183 $wgCodeReviewMaxDiffPaths = 20;
184184
185185 /**
186 - * Limit of the revisions accessible to the search by path.
187 - * Set to 0 to disable the limit.
188 - */
189 -$wgCodeReviewPathSearchHorizon = 20000;
190 -
191 -/**
192186 * Key is repository name. Value is an array of regexes
193187 *
194188 * Any base paths matching regular expressions in these arrays will have their
Index: trunk/extensions/CodeReview/backend/CodeRepository.php
@@ -141,15 +141,6 @@
142142 return intval( $row );
143143 }
144144
145 - public function getPathSearchHorizon() {
146 - global $wgCodeReviewPathSearchHorizon;
147 -
148 - if( $wgCodeReviewPathSearchHorizon )
149 - return $this->getLastStoredRev() - $wgCodeReviewPathSearchHorizon;
150 - else
151 - return 0;
152 - }
153 -
154145 public function getAuthorList() {
155146 global $wgMemc;
156147 $key = wfMemcKey( 'codereview', 'authors', $this->getId() );
Index: trunk/extensions/CodeReview/ui/CodeRevisionListView.php
@@ -205,12 +205,10 @@
206206 $whereCond = array(
207207 'cr_repo_id' => $this->mRepo->getId(),
208208 'cr_id = cp_rev_id',
209 - ' cp_path' . $dbr->buildLike( $this->mPath, $dbr->anyString() ),
210 - // Performance
211 - ' cp_rev_id > ' . $this->mRepo->getPathSearchHorizon()
 209+ 'cp_path' => $this->mPath,
212210 );
213 - // No path; count of code_rev
214211 } else {
 212+ // No path; count of code_rev
215213 $whereCond = array( 'cr_repo_id' => $this->mRepo->getId() );
216214 }
217215 $whereCond = array_merge( $whereCond, $this->getSpecializedWhereClause( $dbr ) );

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r79379*(bug 23720) CodeReview doesn't show ancient revisions for a path...reedy22:55, 31 December 2010
r79381More for bug 23720....reedy23:02, 31 December 2010
r79384Add repopuldateCodePaths maintenance script for bug 23720 (untested, will be ...reedy23:32, 31 December 2010
r79390More refactoring and fixing for bug 23720reedy00:03, 1 January 2011
r79401Minor extra bit for bug 23720, remove performance restrictionreedy01:12, 1 January 2011

Status & tagging log