WikiLambda
MediaWiki WikiLambda extension
Loading...
Searching...
No Matches
MediaWiki\Extension\WikiLambda\ActionAPI\ApiPerformTest Class Reference
+ Inheritance diagram for MediaWiki\Extension\WikiLambda\ActionAPI\ApiPerformTest:
+ Collaboration diagram for MediaWiki\Extension\WikiLambda\ActionAPI\ApiPerformTest:

Public Member Functions

 __construct ( $query, $moduleName, ZObjectStore $zObjectStore)
 
 execute ()
 
 executeGenerator ( $resultPageSet)
 
 isInternal ()
 Mark as internal.
 
- Public Member Functions inherited from MediaWiki\Extension\WikiLambda\ActionAPI\WikiLambdaApiBase
 dieWithZError ( $zerror, $code=400)
 
 setLogger (LoggerInterface $logger)
 @inheritDoc
 
 getLogger ()
 @inheritDoc
 

Static Public Member Functions

static maybeUpdateImplementationRanking ( $functionZid, $functionRevision, $implementationMap, $attachedImplementationZids, $attachedTesterZids)
 Based on tester results contained in $implementationMap, order the implementations of the given function from best-performing to worst-performing (in terms of speed).
 

Protected Member Functions

 getAllowedParams ()
 @inheritDoc @codeCoverageIgnore
 
 getExamplesMessages ()
 
- Protected Member Functions inherited from MediaWiki\Extension\WikiLambda\ActionAPI\WikiLambdaApiBase
 setUp ()
 
 executeFunctionCall ( $zObject, $validate)
 

Additional Inherited Members

- Protected Attributes inherited from MediaWiki\Extension\WikiLambda\ActionAPI\WikiLambdaApiBase
OrchestratorRequest $orchestrator
 
string $orchestratorHost
 
LoggerInterface $logger
 

Member Function Documentation

◆ getExamplesMessages()

MediaWiki\Extension\WikiLambda\ActionAPI\ApiPerformTest::getExamplesMessages ( )
protected
See also
ApiBase::getExamplesMessages()
Returns
array @codeCoverageIgnore

◆ isInternal()

MediaWiki\Extension\WikiLambda\ActionAPI\ApiPerformTest::isInternal ( )

Mark as internal.

This isn't meant to be user-facing, and can change at any time.

Returns
bool

◆ maybeUpdateImplementationRanking()

static MediaWiki\Extension\WikiLambda\ActionAPI\ApiPerformTest::maybeUpdateImplementationRanking ( $functionZid,
$functionRevision,
$implementationMap,
$attachedImplementationZids,
$attachedTesterZids )
static

Based on tester results contained in $implementationMap, order the implementations of the given function from best-performing to worst-performing (in terms of speed).

If the ordering is significantly different than the previous ordering for this function, instantiate an asynchronous job to update Z8K4/implementations in the function's persistent storage.

TODO (T329138): Consider whether average Cpu usage is good enough to determine the ranking. Should we eliminate implementations that are outliers relative to others on the same test? Should we consider non-CPU time needed to, e.g., retrieve info from Wikidata?

Parameters
string$functionZid
int$functionRevision
array$implementationMapcontains $implementationZid => $testerMap, for each tested implementation. $testerMap contains $testerZid => $testResult for each tester. See ApiPerformTest::run for the structure of $testResult.
array$attachedImplementationZids
array$attachedTesterZids

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