r23958 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r23957‎ | r23958 | r23959 >
Date:14:19, 10 July 2007
Author:robchurch
Status:old
Tags:
Comment:
* Code conventions
* Tweak release notes
Modified paths:
  • /trunk/phase3/RELEASE-NOTES (modified) (history)
  • /trunk/phase3/includes/DefaultSettings.php (modified) (history)
  • /trunk/phase3/includes/GlobalFunctions.php (modified) (history)
  • /trunk/phase3/includes/Wiki.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/GlobalFunctions.php
@@ -706,11 +706,9 @@
707707 $now = wfTime();
708708 $elapsed = $now - $wgRequestTime;
709709
710 - if ($wgShowHostnames) {
711 - return sprintf( "<!-- Served by %s in %01.3f secs. -->", wfHostname(), $elapsed );
712 - } else {
713 - return sprintf( "<!-- Served in %01.3f secs. -->", $elapsed );
714 - }
 710+ return $wgShowHostnames
 711+ ? sprintf( "<!-- Served by %s in %01.3f secs. -->", wfHostname(), $elapsed )
 712+ : sprintf( "<!-- Served in %01.3f secs. -->", $elapsed );
715713 }
716714
717715 /**
Index: trunk/phase3/includes/Wiki.php
@@ -58,14 +58,13 @@
5959
6060 function checkMaxLag( $maxLag ) {
6161 global $wgLoadBalancer, $wgShowHostnames;
62 -
6362 list( $host, $lag ) = $wgLoadBalancer->getMaxLag();
6463 if ( $lag > $maxLag ) {
6564 header( 'HTTP/1.1 503 Service Unavailable' );
6665 header( 'Retry-After: ' . max( intval( $maxLag ), 5 ) );
6766 header( 'X-Database-Lag: ' . intval( $lag ) );
6867 header( 'Content-Type: text/plain' );
69 - if ($wgShowHostnames) {
 68+ if( $wgShowHostnames ) {
7069 echo "Waiting for $host: $lag seconds lagged\n";
7170 } else {
7271 echo "Waiting for a database server: $lag seconds lagged\n";
Index: trunk/phase3/includes/DefaultSettings.php
@@ -921,12 +921,12 @@
922922 $wgShowExceptionDetails = false;
923923
924924 /**
925 - * If set to true, exposes host names through API and HTML comments.
 925+ * Expose server host names through the API and various HTML comments
926926 */
927927 $wgShowHostnames = false;
928 -
929 -/** * disable experimental dmoz-like category browsing. Output things like:
930 - * Encyclopedia > Music > Style of Music > Jazz
 928+
 929+/**
 930+ * Use experimental, DMOZ-like category browser
931931 */
932932 $wgUseCategoryBrowser = false;
933933
@@ -2690,6 +2690,4 @@
26912691 * show a more obvious warning.
26922692 */
26932693 $wgSlaveLagWarning = 10;
2694 -$wgSlaveLagCritical = 30;
2695 -
2696 -
 2694+$wgSlaveLagCritical = 30;
\ No newline at end of file
Index: trunk/phase3/RELEASE-NOTES
@@ -25,7 +25,7 @@
2626 * $wgAddGroups, $wgRemoveGroups - Finer control over who can assign which
2727 usergroups
2828 * $wgEnotifImpersonal, $wgEnotifUseJobQ - Bulk mail options for large sites
29 -* $wgShowHostnames - Shows host names in API results and HTML comments
 29+* $wgShowHostnames - Expose server host names through the API and HTML comments
3030
3131 == New features since 1.10 ==
3232

Follow-up revisions

RevisionCommit summaryAuthorDate
r24096Merged revisions 23910-24094 via svnmerge from...david22:38, 14 July 2007

Status & tagging log