jenkins-bot has submitted this change and it was merged. Change subject: Make VisualEditor access RESTbase directly in group0 ......................................................................
Make VisualEditor access RESTbase directly in group0 Bug: T90374 Change-Id: I74a63bc028fdf098dad69437532adfb48bc533ed --- M wmf-config/CommonSettings.php M wmf-config/InitialiseSettings.php 2 files changed, 19 insertions(+), 0 deletions(-) Approvals: Alex Monk: Looks good to me, approved jenkins-bot: Verified diff --git a/wmf-config/CommonSettings.php b/wmf-config/CommonSettings.php index 59a33c7..9ef83c6 100644 --- a/wmf-config/CommonSettings.php +++ b/wmf-config/CommonSettings.php @@ -2030,6 +2030,16 @@ $wgVisualEditorParsoidForwardCookies = true; } + // RESTbase connection configuration + if ( $wmgVisualEditorAccessRESTbaseDirectly ) { + // HACK: $wgServerName is not available yet at this point, it's set by Setup.php + // so use a hook + $wgExtensionFunctions[] = function () { + global $wgServerName, $wgVisualEditorRestbaseURL; + $wgVisualEditorRestbaseURL = "https://rest.wikimedia.org/$wgServerName/v1/page/html/"; + }; + } + // Namespace configuration if ( !$wmgVisualEditorInContentNamespaces ) { $wgVisualEditorNamespaces = array(); // Wipe out default set by VisualEditor.php diff --git a/wmf-config/InitialiseSettings.php b/wmf-config/InitialiseSettings.php index eb3287e..b255030 100644 --- a/wmf-config/InitialiseSettings.php +++ b/wmf-config/InitialiseSettings.php @@ -12323,6 +12323,15 @@ 'svwiktionary' => true, # Per community request ), +// Whether VisualEditor should bypass the MediaWiki layer and contact RESTbase directly for speed +'wmgVisualEditorAccessRESTbaseDirectly' => array( + 'default' => false, + 'mediawikiwiki' => true, + 'testwiki' => true, + 'test2wiki' => true, + 'testwikidatawiki' => true, +), + // Namespaces for VisualEditor to be active in, as well as wgContentNamespaces // NS_VISUALEDITOR is added in CommonSettings.php if wmgUseVisualEditorNamespace is true 'wmgVisualEditorNamespaces' => array( -- To view, visit https://gerrit.wikimedia.org/r/200098 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I74a63bc028fdf098dad69437532adfb48bc533ed Gerrit-PatchSet: 6 Gerrit-Project: operations/mediawiki-config Gerrit-Branch: master Gerrit-Owner: Jforrester <jforres...@wikimedia.org> Gerrit-Reviewer: Alex Monk <kren...@gmail.com> Gerrit-Reviewer: Catrope <roan.katt...@gmail.com> Gerrit-Reviewer: GWicke <gwi...@wikimedia.org> Gerrit-Reviewer: Jforrester <jforres...@wikimedia.org> Gerrit-Reviewer: jenkins-bot <> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits