BBlack has uploaded a new change for review.
https://gerrit.wikimedia.org/r/249129
Change subject: purging: do not VCL-filter on domain regex
......................................................................
purging: do not VCL-filter on domain regex
... because we're now splitting the multicast addresses
themselves, which is far more efficient.
Needs to wait on deploy of mediawiki config change: I8799f7b30
Bug: T116752
Change-Id: I2d2078e7240f16040ecee0fc65059955a0f8d13d
---
M hieradata/labs.yaml
M modules/role/manifests/cache/base.pp
M modules/role/manifests/cache/maps.pp
M modules/role/manifests/cache/misc.pp
M modules/role/manifests/cache/mobile.pp
M modules/role/manifests/cache/parsoid.pp
M modules/role/manifests/cache/text.pp
M modules/role/manifests/cache/upload.pp
M modules/varnish/templates/vcl/wikimedia.vcl.erb
9 files changed, 2 insertions(+), 15 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/operations/puppet
refs/changes/29/249129/1
diff --git a/hieradata/labs.yaml b/hieradata/labs.yaml
index 4d11201..9b09788 100644
--- a/hieradata/labs.yaml
+++ b/hieradata/labs.yaml
@@ -33,8 +33,6 @@
eqiad:
- '127.0.0.1'
role::cache::base::zero_site: 'http://zero.wikimedia.beta.wmflabs.org'
-role::cache::base::purge_host_only_upload_re: '^upload\.beta\.wmflabs\.org$'
-role::cache::base::purge_host_not_upload_re: '^(?!upload\.beta\.wmflabs\.org)'
role::cache::base::static_host: 'deployment.wikimedia.beta.wmflabs.org'
role::cache::base::upload_domain: 'upload.beta.wmflabs.org'
role::cache::base::bits_domain: 'bits.beta.wmflabs.org'
diff --git a/modules/role/manifests/cache/base.pp
b/modules/role/manifests/cache/base.pp
index 824ff7d..10284c4 100644
--- a/modules/role/manifests/cache/base.pp
+++ b/modules/role/manifests/cache/base.pp
@@ -1,7 +1,5 @@
class role::cache::base(
$zero_site = 'https://zero.wikimedia.org',
- $purge_host_only_upload_re = '^upload\.wikimedia\.org$',
- $purge_host_not_upload_re = '^(?!upload\.wikimedia\.org)',
$static_host = 'www.wikimedia.org',
$upload_domain = 'upload.wikimedia.org',
$bits_domain = 'bits.wikimedia.org',
diff --git a/modules/role/manifests/cache/maps.pp
b/modules/role/manifests/cache/maps.pp
index 3ed6f2b..188dd8a 100644
--- a/modules/role/manifests/cache/maps.pp
+++ b/modules/role/manifests/cache/maps.pp
@@ -38,7 +38,6 @@
$common_vcl_config = {
'cache4xx' => '1m',
- 'purge_host_regex' => $::role::cache::base::purge_host_not_upload_re,
'do_gzip' => true,
}
diff --git a/modules/role/manifests/cache/misc.pp
b/modules/role/manifests/cache/misc.pp
index b0d1e8c..c1d2d20 100644
--- a/modules/role/manifests/cache/misc.pp
+++ b/modules/role/manifests/cache/misc.pp
@@ -27,7 +27,6 @@
'layer' => 'frontend',
'do_gzip' => true,
'allowed_methods' => '^(GET|DELETE|HEAD|POST|PURGE|PUT)$',
- 'purge_host_regex' =>
$::role::cache::base::purge_host_not_upload_re,
},
directors => {
'analytics1001' => { # Hadoop Yarn ResourceManager GUI
diff --git a/modules/role/manifests/cache/mobile.pp
b/modules/role/manifests/cache/mobile.pp
index 7ba7ec9..1cad83e 100644
--- a/modules/role/manifests/cache/mobile.pp
+++ b/modules/role/manifests/cache/mobile.pp
@@ -78,7 +78,6 @@
$common_vcl_config = {
'cache4xx' => '1m',
- 'purge_host_regex' => $::role::cache::base::purge_host_not_upload_re,
'static_host' => $::role::cache::base::static_host,
'bits_domain' => $::role::cache::base::bits_domain,
'top_domain' => $::role::cache::base::top_domain,
diff --git a/modules/role/manifests/cache/parsoid.pp
b/modules/role/manifests/cache/parsoid.pp
index 131e144..d45bfe4 100644
--- a/modules/role/manifests/cache/parsoid.pp
+++ b/modules/role/manifests/cache/parsoid.pp
@@ -20,7 +20,6 @@
include role::cache::ssl::unified
$common_vcl_config = {
- 'purge_host_regex' => $::role::cache::base::purge_host_not_upload_re,
}
$be_vcl_config = merge($common_vcl_config, {
diff --git a/modules/role/manifests/cache/text.pp
b/modules/role/manifests/cache/text.pp
index a4c4de7..72a949d 100644
--- a/modules/role/manifests/cache/text.pp
+++ b/modules/role/manifests/cache/text.pp
@@ -78,7 +78,6 @@
$common_vcl_config = {
'cache4xx' => '1m',
- 'purge_host_regex' => $::role::cache::base::purge_host_not_upload_re,
'static_host' => $::role::cache::base::static_host,
'bits_domain' => $::role::cache::base::bits_domain,
'top_domain' => $::role::cache::base::top_domain,
diff --git a/modules/role/manifests/cache/upload.pp
b/modules/role/manifests/cache/upload.pp
index c63bea0..5a6e075 100644
--- a/modules/role/manifests/cache/upload.pp
+++ b/modules/role/manifests/cache/upload.pp
@@ -49,7 +49,6 @@
$common_vcl_config = {
'cache4xx' => '1m',
- 'purge_host_regex' => $::role::cache::base::purge_host_only_upload_re,
'upload_domain' => $::role::cache::base::upload_domain,
'do_gzip' => true,
}
diff --git a/modules/varnish/templates/vcl/wikimedia.vcl.erb
b/modules/varnish/templates/vcl/wikimedia.vcl.erb
index 0cb856f..412f485 100644
--- a/modules/varnish/templates/vcl/wikimedia.vcl.erb
+++ b/modules/varnish/templates/vcl/wikimedia.vcl.erb
@@ -359,12 +359,9 @@
if (req.request == "PURGE") {
if (!client.ip ~ purge) {
error 405 "Denied.";
- } elsif (req.http.Host ~ "<%=
@vcl_config.fetch('purge_host_regex') %>") {
- set req.hash_ignore_busy = true;
- return (lookup);
- } else {
- error 204 "Domain not cached here.";
}
+ set req.hash_ignore_busy = true;
+ return (lookup);
}
}
--
To view, visit https://gerrit.wikimedia.org/r/249129
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I2d2078e7240f16040ecee0fc65059955a0f8d13d
Gerrit-PatchSet: 1
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: BBlack <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits