mediawiki-extensions-Popups/extension.json
Baha 9a94300858 Log events to statsv for monitoring PagePreviews performance
For logging to work:
1. $wgWMEStatsdBaseUri needs to point to a valid statsv endpoint,
   e.g. 'https://en.wikipedia.org/beacon/statsv'.
2. $wgPopupsStatsvSamplingRate needs to be set. Note that the codebase
   already contains the EventLogging functionality, which is configured
   separately. Separately configuring different logging mechanisms
   allows us to avoid sampling mistakes that may arise while choosing
   one or the other. For example, let's say we want to use EventLogging for
   10% of users and statsv for 5%. We'd sample all users into two
   buckets: 50/50. And then we'd have to set the sampling rates as
   20% and 10% respectively, only because of the bucketing above. To avoid
   this kind of complications, separate sampling rates are used for each
   logging mechanism. This, of course, may result in situations where a
   session is logged via both EventLogging and statsv.
3. The WikimediaEvents extension needs to be installed. The extension
   adds the `ext.wikimediaEvents` module to the output page. The
   logging functionality is delegated to this module.

Notable changes:
* The FETCH_START and FETCH_END actions are converted to a timed action.
* The experiments stub used in tests has been extracted to the stubs
  file.

Logged data is visualized at
https://grafana.wikimedia.org/dashboard/db/reading-web-page-previews

Bug: T157111
Change-Id: If3f1a06f1f623e8e625b6c30a48b7f5aa9de24db
2017-03-14 08:51:10 +00:00

129 lines
4.2 KiB
JSON

{
"name": "Popups",
"author": [
"Prateek Saxena",
"Yair Rand"
],
"url": "https://www.mediawiki.org/wiki/Extension:Popups",
"descriptionmsg": "popups-desc",
"license-name": "GPL-2.0+",
"type": "betafeatures",
"AutoloadClasses": {
"Popups\\PopupsHooks": "includes/PopupsHooks.php",
"Popups\\PopupsContext": "includes/PopupsContext.php",
"Popups\\PopupsGadgetsIntegration": "includes/PopupsGadgetsIntegration.php"
},
"ConfigRegistry": {
"popups": "GlobalVarConfig::newInstance"
},
"Hooks": {
"GetBetaFeaturePreferences": [
"Popups\\PopupsHooks::onGetBetaPreferences"
],
"BeforePageDisplay": [
"Popups\\PopupsHooks::onBeforePageDisplay"
],
"ResourceLoaderTestModules": [
"Popups\\PopupsHooks::onResourceLoaderTestModules"
],
"ResourceLoaderGetConfigVars": [
"Popups\\PopupsHooks::onResourceLoaderGetConfigVars"
],
"GetPreferences": [
"Popups\\PopupsHooks::onGetPreferences"
],
"UserGetDefaultOptions": [
"Popups\\PopupsHooks::onUserGetDefaultOptions"
],
"MakeGlobalVariablesScript": [
"Popups\\PopupsHooks::onMakeGlobalVariablesScript"
]
},
"MessagesDirs": {
"Popups": [
"i18n"
]
},
"EventLoggingSchemas": {
"Popups": 16364296
},
"config": {
"@PopupsBetaFeature": "@var bool: Whether the extension should be enabled as an opt-in beta feature. If true, the BetaFeatures extension must be installed. False by default.",
"PopupsBetaFeature": false,
"@PopupsSchemaSamplingRate": "@var number: Sample rate for logging events to Schema:Popups.",
"PopupsSchemaSamplingRate": 0,
"@PopupsHideOptInOnPreferencesPage": "@var bool: Whether the option to senable/disable Page Previews should be hidden on Preferences page. Please note if PopupsBetaFeature is set to true this option will be always hidden. False by default",
"PopupsHideOptInOnPreferencesPage": false,
"@PopupsOptInDefaultState" : "@var string:['1'|'0'] Default Page Previews visibility. Has to be a string as a compatibility with beta feature settings",
"PopupsOptInDefaultState" : "0",
"@PopupsConflictingNavPopupsGadgetName": "@var string: Navigation popups gadget name",
"PopupsConflictingNavPopupsGadgetName": "Navigation_popups",
"@PopupsAPIUseRESTBase": "Whether to use RESTBase rather than the MediaWiki API for fetching Popups data.",
"PopupsAPIUseRESTBase": false,
"@PopupsAnonsEnabledSamplingRate": "Sampling rate for showing popups to anonymous users.",
"PopupsAnonsEnabledSamplingRate": 0.9,
"@PopupsStatsvSamplingRate": "Sampling rate for logging performance data to statsv.",
"PopupsStatsvSamplingRate": 0
},
"ResourceModules": {
"ext.popups.images": {
"selector": ".mw-ui-icon-{name}:before",
"class": "ResourceLoaderImageModule",
"prefix": "mw-ui",
"images": {
"popups-close": "resources/ext.popups.images/close.svg"
}
},
"ext.popups": {
"scripts": [
"resources/dist/index.js"
],
"templates": {
"preview.mustache": "resources/ext.popups/templates/preview.mustache",
"preview-empty.mustache": "resources/ext.popups/templates/preview-empty.mustache",
"settings.mustache": "resources/ext.popups/templates/settings.mustache"
},
"styles": [
"resources/ext.popups/styles/ext.popups.core.less",
"resources/ext.popups/styles/ext.popups.animation.less",
"resources/ext.popups/styles/ext.popups.settings.less"
],
"messages": [
"popups-settings-title",
"popups-settings-description",
"popups-settings-option-simple",
"popups-settings-option-simple-description",
"popups-settings-option-advanced",
"popups-settings-option-advanced-description",
"popups-settings-option-off",
"popups-settings-save",
"popups-settings-cancel",
"popups-settings-enable",
"popups-settings-help",
"popups-settings-help-ok",
"popups-send-feedback",
"popups-preview-no-preview",
"popups-preview-footer-read"
],
"dependencies": [
"es5-shim",
"ext.popups.images",
"mediawiki.experiments",
"mediawiki.storage",
"mediawiki.Title",
"mediawiki.jqueryMsg",
"mediawiki.ui.button",
"mediawiki.ui.icon",
"mediawiki.Uri",
"jquery.hidpi",
"ext.eventLogging.Schema"
]
}
},
"ResourceFileModulePaths": {
"localBasePath": "",
"remoteExtPath": "Popups"
},
"manifest_version": 1
}