In my wiki installation (which is running on Windows/IIS6/MSSQL) I have
modified the finalCleanup method in Wiki.php to do this:
function finalCleanup ( &$deferredUpdates, &$output ) {
wfProfileIn( __METHOD__ );
$this->doUpdates( $deferredUpdates );
$output->output();
$this->doJobs();
# Now commit any transactions, so that unreported errors after output()
don't roll back the whole thing
$factory = wfGetLBFactory();
$factory->shutdown();
wfProfileOut( __METHOD__ );
}
rather than this:
function finalCleanup ( &$deferredUpdates, &$output ) {
wfProfileIn( __METHOD__ );
$this->doUpdates( $deferredUpdates );
$this->doJobs();
# Now commit any transactions, so that unreported errors after output()
don't roll back the whole thing
$factory = wfGetLBFactory();
$factory->shutdown();
$output->output();
wfProfileOut( __METHOD__ );
}
Basically, I am flushing the output before running anything from my job
queue. I frequently have a non-empty job queue, and have found that the
modification lets the browser see the page much faster than when I run some
jobs first. Is there any reason not to suggest this as a change to the code
base? It made quite a dramatic improvement on my wiki when I made the
change, although perhaps things are different with Linux/Apache/MySQL?