Add page purge limiter
[lhc/web/wiklou.git] / includes / DefaultSettings.php
index c5fdbac..339ae9b 100644 (file)
@@ -75,7 +75,7 @@ $wgConfigRegistry = array(
  * MediaWiki version number
  * @since 1.2
  */
-$wgVersion = '1.26alpha';
+$wgVersion = '1.27alpha';
 
 /**
  * Name of the site. It must be changed in LocalSettings.php
@@ -525,6 +525,14 @@ $wgForeignFileRepos = array();
  */
 $wgUseInstantCommons = false;
 
+/**
+ * Name of the remote repository to which users will be allowed to upload
+ * files in their editors. Used to find a set of message names to describe
+ * the legal requirements for uploading to that wiki, and suggestions for
+ * when those requirements are not met.
+ */
+$wgRemoteUploadTarget = 'default';
+
 /**
  * File backend structure configuration.
  *
@@ -867,12 +875,12 @@ $wgUploadSizeWarning = false;
  * [[media:...]] links for non-trusted formats.
  */
 $wgTrustedMediaFormats = array(
-       MEDIATYPE_BITMAP, //all bitmap formats
-       MEDIATYPE_AUDIO, //all audio formats
-       MEDIATYPE_VIDEO, //all plain video formats
-       "image/svg+xml", //svg (only needed if inline rendering of svg is not supported)
-       "application/pdf", //PDF files
-       #"application/x-shockwave-flash", //flash/shockwave movie
+       MEDIATYPE_BITMAP, // all bitmap formats
+       MEDIATYPE_AUDIO, // all audio formats
+       MEDIATYPE_VIDEO, // all plain video formats
+       "image/svg+xml", // svg (only needed if inline rendering of svg is not supported)
+       "application/pdf", // PDF files
+       # "application/x-shockwave-flash", //flash/shockwave movie
 );
 
 /**
@@ -1173,7 +1181,7 @@ $wgAntivirus = null;
  */
 $wgAntivirusSetup = array(
 
-       #setup for clamav
+       # setup for clamav
        'clamav' => array(
                'command' => 'clamscan --no-summary ',
                'codemap' => array(
@@ -1860,6 +1868,32 @@ $wgDBservers = false;
  */
 $wgLBFactoryConf = array( 'class' => 'LBFactorySimple' );
 
+/**
+ * The ID of the current data center
+ * @since 1.27
+ */
+$wgDataCenterId = 'default';
+
+/**
+ * Map of data center IDs to their role ("master" or "slave")
+ *
+ * Multiple data centers can be setup to handle MediaWiki, with HTTP
+ * POSTs routed to the master data center and GET/HEAD/OPTION routed to
+ * any data center (usually the closest to the end user). In such setups,
+ * this setting should be set to the appropriate value in the site
+ * config for each data center.
+ * @since 1.27
+ */
+$wgDataCenterRoles = array( 'default' => 'master' );
+
+/**
+ * After a state-changing request is done by a client, this determines
+ * how many seconds that client should keep using the master datacenter.
+ * This avoids unexpected stale or 404 responses due to replication lag.
+ * @since 1.27
+ */
+$wgDataCenterUpdateStickTTL = 10;
+
 /**
  * File to log database errors to
  */
@@ -3515,6 +3549,8 @@ $wgResourceLoaderDebug = false;
 /**
  * Put each statement on its own line when minifying JavaScript. This makes
  * debugging in non-debug mode a bit easier.
+ *
+ * @deprecated since 1.27: Always false; no longer configurable.
  */
 $wgResourceLoaderMinifierStatementsOnOwnLine = false;
 
@@ -3522,6 +3558,8 @@ $wgResourceLoaderMinifierStatementsOnOwnLine = false;
  * Maximum line length when minifying JavaScript. This is not a hard maximum:
  * the minifier will try not to produce lines longer than this, but may be
  * forced to do so in certain cases.
+ *
+ * @deprecated since 1.27: Always 1,000; no longer configurable.
  */
 $wgResourceLoaderMinifierMaxLineLength = 1000;
 
@@ -4003,7 +4041,7 @@ $wgInvalidRedirectTargets = array( 'Filepath', 'Mypage', 'Mytalk', 'Redirect' );
  */
 $wgParserConf = array(
        'class' => 'Parser',
-       #'preprocessorClass' => 'Preprocessor_Hash',
+       # 'preprocessorClass' => 'Preprocessor_Hash',
 );
 
 /**
@@ -4462,6 +4500,7 @@ $wgReservedUsernames = array(
        'msg:usermessage-editor', // Default user for leaving user messages
        'msg:proxyblocker', // For $wgProxyList and Special:Blockme (removed in 1.22)
        'msg:spambot_username', // Used by cleanupSpam.php
+       'msg:autochange-username', // Used by anon category RC entries (parser functions, Lua & purges)
 );
 
 /**
@@ -4573,7 +4612,7 @@ $wgAutoblockExpiry = 86400;
 /**
  * Set this to true to allow blocked users to edit their own user talk page.
  */
-$wgBlockAllowsUTEdit = false;
+$wgBlockAllowsUTEdit = true;
 
 /**
  * Allow sysops to ban users from accessing Emailuser
@@ -4702,7 +4741,7 @@ $wgGroupPermissions['*']['editmywatchlist'] = true;
 $wgGroupPermissions['*']['viewmyprivateinfo'] = true;
 $wgGroupPermissions['*']['editmyprivateinfo'] = true;
 $wgGroupPermissions['*']['editmyoptions'] = true;
-#$wgGroupPermissions['*']['patrolmarks'] = false; // let anons see what was patrolled
+# $wgGroupPermissions['*']['patrolmarks'] = false; // let anons see what was patrolled
 
 // Implicit group for all logged-in accounts
 $wgGroupPermissions['user']['move'] = true;
@@ -4780,8 +4819,8 @@ $wgGroupPermissions['sysop']['noratelimit'] = true;
 $wgGroupPermissions['sysop']['movefile'] = true;
 $wgGroupPermissions['sysop']['unblockself'] = true;
 $wgGroupPermissions['sysop']['suppressredirect'] = true;
-#$wgGroupPermissions['sysop']['pagelang'] = true;
-#$wgGroupPermissions['sysop']['upload_by_url'] = true;
+# $wgGroupPermissions['sysop']['pagelang'] = true;
+# $wgGroupPermissions['sysop']['upload_by_url'] = true;
 $wgGroupPermissions['sysop']['mergehistory'] = true;
 $wgGroupPermissions['sysop']['managechangetags'] = true;
 
@@ -4789,20 +4828,20 @@ $wgGroupPermissions['sysop']['managechangetags'] = true;
 $wgGroupPermissions['bureaucrat']['userrights'] = true;
 $wgGroupPermissions['bureaucrat']['noratelimit'] = true;
 // Permission to change users' groups assignments across wikis
-#$wgGroupPermissions['bureaucrat']['userrights-interwiki'] = true;
+# $wgGroupPermissions['bureaucrat']['userrights-interwiki'] = true;
 // Permission to export pages including linked pages regardless of $wgExportMaxLinkDepth
-#$wgGroupPermissions['bureaucrat']['override-export-depth'] = true;
+# $wgGroupPermissions['bureaucrat']['override-export-depth'] = true;
 
-#$wgGroupPermissions['sysop']['deletelogentry'] = true;
-#$wgGroupPermissions['sysop']['deleterevision'] = true;
+# $wgGroupPermissions['sysop']['deletelogentry'] = true;
+# $wgGroupPermissions['sysop']['deleterevision'] = true;
 // To hide usernames from users and Sysops
-#$wgGroupPermissions['suppress']['hideuser'] = true;
+# $wgGroupPermissions['suppress']['hideuser'] = true;
 // To hide revisions/log items from users and Sysops
-#$wgGroupPermissions['suppress']['suppressrevision'] = true;
+# $wgGroupPermissions['suppress']['suppressrevision'] = true;
 // To view revisions/log items hidden from users and Sysops
-#$wgGroupPermissions['suppress']['viewsuppressed'] = true;
+# $wgGroupPermissions['suppress']['viewsuppressed'] = true;
 // For private suppression log access
-#$wgGroupPermissions['suppress']['suppressionlog'] = true;
+# $wgGroupPermissions['suppress']['suppressionlog'] = true;
 
 /**
  * The developer group is deprecated, but can be activated if need be
@@ -5208,6 +5247,13 @@ $wgRateLimits = array(
                'user' => null,
                'newbie' => null,
        ),
+       'purge' => array( // purging pages
+               'anon' => null,
+               'user' => null,
+               'newbie' => null,
+               'ip' => null,
+               'subnet' => null,
+       ),
 );
 
 /**
@@ -6664,6 +6710,7 @@ $wgHooks = array();
  */
 $wgJobClasses = array(
        'refreshLinks' => 'RefreshLinksJob',
+       'deleteLinks' => 'DeleteLinksJob',
        'htmlCacheUpdate' => 'HTMLCacheUpdateJob',
        'sendMail' => 'EmaillingJob',
        'enotifNotify' => 'EnotifNotifyJob',
@@ -6934,11 +6981,7 @@ $wgLogHeaders = array(
  *
  * Extensions with custom log types may add to this array.
  */
-$wgLogActions = array(
-       'protect/modify' => 'modifiedarticleprotection',
-       'protect/protect' => 'protectedarticle',
-       'protect/unprotect' => 'unprotectedarticle',
-);
+$wgLogActions = array();
 
 /**
  * The same as above, but here values are names of classes,
@@ -6965,7 +7008,10 @@ $wgLogActionsHandlers = array(
        'move/move' => 'MoveLogFormatter',
        'move/move_redir' => 'MoveLogFormatter',
        'patrol/patrol' => 'PatrolLogFormatter',
+       'protect/modify' => 'ProtectLogFormatter',
        'protect/move_prot' => 'ProtectLogFormatter',
+       'protect/protect' => 'ProtectLogFormatter',
+       'protect/unprotect' => 'ProtectLogFormatter',
        'rights/autopromote' => 'RightsLogFormatter',
        'rights/rights' => 'RightsLogFormatter',
        'suppress/block' => 'BlockLogFormatter',
@@ -7473,7 +7519,7 @@ $wgRunJobsAsync = true;
 /**
  * Number of rows to update per job
  */
-$wgUpdateRowsPerJob = 500;
+$wgUpdateRowsPerJob = 300;
 
 /**
  * Number of rows to update per query
@@ -7668,14 +7714,6 @@ $wgHKDFAlgorithm = 'sha256';
  */
 $wgPageLanguageUseDB = false;
 
-/**
- * Enable use of the *_namespace fields of the pagelinks, redirect, and templatelinks tables.
- * Set this only if the fields are fully populated. This may be removed in 1.25.
- * @var bool
- * @since 1.24
- */
-$wgUseLinkNamespaceDBFields = true;
-
 /**
  * Global configuration variable for Virtual REST Services.
  * Parameters for different services are to be declared inside
@@ -7707,14 +7745,13 @@ $wgVirtualRestConfig = array(
 );
 
 /**
- * Controls the percentage of zero-result search queries with suggestions that
- * run the suggestion automatically. Must be a number between 0 and 1.  This
- * can be lowered to reduce query volume at the expense of result quality.
+ * Controls whether zero-result search queries with suggestions should display results for
+ * these suggestions.
  *
- * @var float
+ * @var bool
  * @since 1.26
  */
-$wgSearchRunSuggestedQueryPercent = 1;
+$wgSearchRunSuggestedQuery = true;
 
 /**
  * For really cool vim folding this needs to be at the end: