手册:$wgMiserMode
| 性能修改和限制: $wgMiserMode | |
|---|---|
| 啟用/停用資料庫密集型功能 |
|
| 引进版本: | 1.1.0前 |
| 移除版本: | 仍在使用 |
| 允许的值: | (布尔值) |
| 默认值: | false |
| 其他设置: 按首字母排序 | 按功能排序 | |
吝啬模式(Miser mode)是为了给一台服务器上运行大量Wiki的情况减小负载而准备的。所有维基媒体基金会的wiki上都启用了这个功能。
详情
如果true,禁用数据库密集型的功能,以便在需要时可以单独管理/控制。
这包括从缓存中读取标记为高开销的特殊页面,而非在每次请求时重新生成。
当$wgMiserMode设定为true,则受此标志管理的特殊页面只在明确要求更新时被更新。
例如,使用Extension:RefreshSpecial设置一个调用/maintenance/updateSpecialPages.php的cron任务。
其他被停用的功能有...
- 通过MediaWiki:Rc-change-size(r48986)禁用Special:最近更改中更改大小的自定义格式设置
- 禁用选择Special:日志中所有以“x”开头的页面复选框(以及
list=logeventsAPI模块的leprefix选项) - 在
list=allimages和list=filearchiveAPI模块中禁用aimime和famime选项。 不过,Special:MIMESearch 允许在 gerrit:67468 之后运行。 - 禁用Special:Contributions的RSS提要的
showsizediff选项
在list=categorymembers和list=externallinks API模块中,采用了按命名空间精简排序模式(当使用cmnamespace或elnamespace选项时仅返回少量结果)。
- Similarly disables the filter by namespace box on Special:LinkSearch
- Doesn't update number of active users on Special:Statistics quite as often (?)
- Disables the search for images with x somewhere in their name box on Special:NewImages and Special:ListFiles
- Do not show how many previous versions of an image were uploaded on Special:ListFiles
- When running rebuildrecentchanges.php maintenance script, will not re-auto-patrol edits by users with auto-patrol flag.
- When running updateCollation.php maintenance script, will not tell you how many rows in total there are to update.
| MediaWiki版本: | ≥ 1.23 Gerrit change 109710 |
- Disables transclusion count on info action as of gerrit:109710.
| MediaWiki版本: | 1.33 – 1.34 Gerrit change 294774 |
- Disables the
{{REVISIONID}}magic word in content namespaces as defined with $wgContentNamespaces as of gerrit:294774.
It is substituted by a single dash after saving the page.
| MediaWiki版本: | ≥ 1.35 Gerrit change 570985 |
- Disables the
{{REVISIONID}}magic word in subject namespaces as of gerrit:570985.
It is substituted by a single dash after saving the page.
For reference, this very wiki uses miser mode.
You can tell if a wiki has miser mode enabled via the meta=siteinfo API module.
update.php
| MediaWiki版本: | 1.18 |
This configuration option disables update.php in 1.18.0 (and only 1.18.0. Subsequent releases will not use this option for that purpose), requiring one to use --force to run that script.
Very very very large wikis (like Wikipedia) may need to have more careful upgrade process than the maintenance script does, but most sites would not have to worry about this.