MediaWiki  REL1_22
BenchmarkPurge Class Reference

Maintenance script that benchmarks Squid purge. More...

Inheritance diagram for BenchmarkPurge:
Collaboration diagram for BenchmarkPurge:

List of all members.

Public Member Functions

 __construct ()
 execute ()

Private Member Functions

 benchSquid ($urls, $trials=1)
 Run a bunch of URLs through SquidUpdate::purge() to benchmark Squid response times.
 randomTitle ()
 Create a random title string (not necessarily a Title object).
 randomUrl ()
 Return a random URL of the wiki.
 randomUrlList ($length)
 Get an array of randomUrl()'s.

Detailed Description

Maintenance script that benchmarks Squid purge.

Definition at line 31 of file benchmarkPurge.php.


Constructor & Destructor Documentation

Reimplemented from Benchmarker.

Definition at line 33 of file benchmarkPurge.php.


Member Function Documentation

BenchmarkPurge::benchSquid ( urls,
trials = 1 
) [private]

Run a bunch of URLs through SquidUpdate::purge() to benchmark Squid response times.

Parameters:
$urlsarray A bunch of URLs to purge
$trialsint How many times to run the test?
Returns:
string

Definition at line 64 of file benchmarkPurge.php.

References $urls, and SquidUpdate\purge().

Referenced by execute().

Create a random title string (not necessarily a Title object).

For use with randomUrl().

Returns:
string

Definition at line 104 of file benchmarkPurge.php.

Referenced by randomUrl().

Return a random URL of the wiki.

Not necessarily an actual title in the database, but at least a URL that looks like one.

Returns:
string

Definition at line 94 of file benchmarkPurge.php.

References $wgArticlePath, global, and randomTitle().

Referenced by randomUrlList().

BenchmarkPurge::randomUrlList ( length) [private]

Get an array of randomUrl()'s.

Parameters:
$lengthint How many urls to add to the array
Returns:
array

Definition at line 81 of file benchmarkPurge.php.

References array(), and randomUrl().

Referenced by execute().


The documentation for this class was generated from the following file: