Asher has submitted this change and it was merged.

Change subject: use twemproxy on all apaches
......................................................................


use twemproxy on all apaches

Change-Id: I42bb5610badd2ab038d08fa357820d61c3c02771
---
M wmf-config/mc-eqiad.php
M wmf-config/mc-pmtpa.php
2 files changed, 31 insertions(+), 11 deletions(-)

Approvals:
  Aaron Schulz: Looks good to me, but someone else must approve
  Asher: Verified; Looks good to me, approved
  jenkins-bot: Verified



diff --git a/wmf-config/mc-eqiad.php b/wmf-config/mc-eqiad.php
index c13ba18..6eb2ad9 100644
--- a/wmf-config/mc-eqiad.php
+++ b/wmf-config/mc-eqiad.php
@@ -10,16 +10,20 @@
 # rather a consistent hash based on key and server addresses,
 # so the ordering of servers is not important. Additionally, the
 # number of servers can grow/shrink without *too* much disruption.
-if (strpos(gethostname(), "mw113") !== false ) {
-       $wgObjectCaches['memcached-pecl'] = array(
-               'class'      => 'MemcachedPeclBagOStuff',
-               'serializer' => 'igbinary',
-               'persistent' => true,
-               'servers'    => array( '127.0.0.1' ),
-               'server_failure_limit' => 0,
-               'retry_timeout' => 0
-       );
-} else {
+
+# Use twemproxy for memcached access - see twemproxy-eqiad.yaml
+# NOTE: after deploying a new twemproxy.yaml config, run restart-twemproxy
+# from the deploy host to make it live.
+$wgObjectCaches['memcached-pecl'] = array(
+       'class'      => 'MemcachedPeclBagOStuff',
+       'serializer' => 'igbinary',
+       'persistent' => true,
+       'servers'    => array( '127.0.0.1' ),
+       'server_failure_limit' => 0,
+       'retry_timeout' => 0
+);
+
+/*** No Twemproxy
        $wgObjectCaches['memcached-pecl'] = array(
                'class'      => 'MemcachedPeclBagOStuff',
                'serializer' => 'igbinary',
@@ -42,5 +46,6 @@
                        '10.64.0.195',
                )
        );
-}
+***/
+
 # vim: set sts=4 sw=4 et :
diff --git a/wmf-config/mc-pmtpa.php b/wmf-config/mc-pmtpa.php
index 41adcd0..25d4306 100644
--- a/wmf-config/mc-pmtpa.php
+++ b/wmf-config/mc-pmtpa.php
@@ -10,6 +10,20 @@
 # rather a consistent hash based on key and server addresses,
 # so the ordering of servers is not important. Additionally, the
 # number of servers can grow/shrink without *too* much disruption.
+
+# Use twemproxy for memcached access - see twemproxy-pmtpa.yaml
+# NOTE: after deploying a new twemproxy.yaml config, run restart-twemproxy
+# from the deploy host to make it live.
+$wgObjectCaches['memcached-pecl'] = array(
+       'class'      => 'MemcachedPeclBagOStuff',
+       'serializer' => 'igbinary',
+       'persistent' => true,
+       'servers'    => array( '127.0.0.1' ),
+       'server_failure_limit' => 0,
+       'retry_timeout' => 0
+);
+
+/*** No Twemproxy
 $wgObjectCaches['memcached-pecl'] = array(
        'class'      => 'MemcachedPeclBagOStuff',
        'serializer' => 'igbinary',
@@ -32,5 +46,6 @@
                '10.0.12.16',
        )
 );
+***/
 
 # vim: set sts=4 sw=4 et :

-- 
To view, visit https://gerrit.wikimedia.org/r/68308
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I42bb5610badd2ab038d08fa357820d61c3c02771
Gerrit-PatchSet: 3
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Asher <afeld...@wikimedia.org>
Gerrit-Reviewer: Aaron Schulz <asch...@wikimedia.org>
Gerrit-Reviewer: Asher <afeld...@wikimedia.org>
Gerrit-Reviewer: jenkins-bot

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to