$repo = RepoGroup::singleton()->getLocalRepo();
$dbr = $repo->getReplicaDB();
$be = $repo->getBackend();
+ $batchSize = $this->getBatchSize();
$mtime1 = $dbr->timestampOrNull( $this->getOption( 'mtimeafter', null ) );
$mtime2 = $dbr->timestampOrNull( $this->getOption( 'mtimebefore', null ) );
__METHOD__,
// DISTINCT causes a pointless filesort
[ 'ORDER BY' => 'name', 'GROUP BY' => 'name',
- 'LIMIT' => $this->mBatchSize ],
+ 'LIMIT' => $batchSize ],
$joinConds
);
$checkPaths[] = $file->getPath();
}
- foreach ( array_chunk( $checkPaths, $this->mBatchSize ) as $paths ) {
+ foreach ( array_chunk( $checkPaths, $batchSize ) as $paths ) {
$be->preloadFileStat( [ 'srcs' => $paths ] );
foreach ( $paths as $path ) {
if ( $be->fileExists( [ 'src' => $path ] ) === false ) {
}
}
}
- } while ( $res->numRows() >= $this->mBatchSize );
+ } while ( $res->numRows() >= $batchSize );
}
}
-$maintClass = 'FindMissingFiles';
+$maintClass = FindMissingFiles::class;
require_once RUN_MAINTENANCE_IF_MAIN;