Revision::getRevisionText should take wiki identifier, to allow for the loading
of revision blobs from another wiki's database. This is passed through to
ExternalStoreDB, so it uses the correct database connection.
Change-Id: I14a7ebb8aa31a4e50735db9c28ff8d2759cd872c
*
* @param $row Object: the text data
* @param $prefix String: table prefix (default 'old_')
*
* @param $row Object: the text data
* @param $prefix String: table prefix (default 'old_')
+ * @param $wiki String|false: the name of the wiki to load the revision text from
+ * (same as the the wiki $row was loaded from) or false to indicate the local
+ * wiki (this is the default). Otherwise, it must be a symbolic wiki database
+ * identifier as understood by the LoadBalancer class.
* @return String: text the text requested or false on failure
*/
* @return String: text the text requested or false on failure
*/
- public static function getRevisionText( $row, $prefix = 'old_' ) {
+ public static function getRevisionText( $row, $prefix = 'old_', $wiki = false ) {
wfProfileIn( __METHOD__ );
# Get data
wfProfileIn( __METHOD__ );
# Get data
wfProfileOut( __METHOD__ );
return false;
}
wfProfileOut( __METHOD__ );
return false;
}
- $text = ExternalStore::fetchFromURL( $url );
+ $text = ExternalStore::fetchFromURL( $url, array( 'wiki' => $wiki ) );
}
// If the text was fetched without an error, convert it
}
// If the text was fetched without an error, convert it