EBernhardson has uploaded a new change for review.
https://gerrit.wikimedia.org/r/252869
Change subject: Record the test bucket in CirrusSearchRequestSet log
......................................................................
Record the test bucket in CirrusSearchRequestSet log
This log records the name of the test a user is participating in,
but it does not say which bucket. To be able to deprecate the old
CirrusSearchUserTesting logs we need this information here.
Change-Id: I71e72e8034e567733a6ca52f5a563d760bc143bd
---
M includes/ElasticsearchIntermediary.php
M includes/UserTesting.php
2 files changed, 9 insertions(+), 1 deletion(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/CirrusSearch
refs/changes/69/252869/1
diff --git a/includes/ElasticsearchIntermediary.php
b/includes/ElasticsearchIntermediary.php
index 7645014..72b79d5 100644
--- a/includes/ElasticsearchIntermediary.php
+++ b/includes/ElasticsearchIntermediary.php
@@ -179,7 +179,7 @@
'identity' => self::generateIdentToken(),
'ip' => $wgRequest->getIP() ?: '',
'userAgent' => $wgRequest->getHeader( 'User-Agent') ?:
'',
- 'backendUserTests' =>
UserTesting::getInstance()->getActiveTestNames(),
+ 'backendUserTests' =>
UserTesting::getInstance()->getActiveTestNamesWithBucket(),
'requests' => $requests,
);
diff --git a/includes/UserTesting.php b/includes/UserTesting.php
index 2e8065c..f8d8709 100644
--- a/includes/UserTesting.php
+++ b/includes/UserTesting.php
@@ -120,6 +120,14 @@
return array_keys( $this->tests );
}
+ public function getActiveTestNamesWithBucket() {
+ $result = array();
+ foreach ( $this->tests as $test => $bucket ) {
+ $result[] = "$test:$bucket";
+ }
+ return $result;
+ }
+
/**
* @var string $testName Name of the test to activate.
* @var float $bucketProbability Number between 0 and 1 for determining
bucket.
--
To view, visit https://gerrit.wikimedia.org/r/252869
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I71e72e8034e567733a6ca52f5a563d760bc143bd
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/CirrusSearch
Gerrit-Branch: master
Gerrit-Owner: EBernhardson <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits