8000 drop varnish 2 example from varnish cookbook article · aitboudad/symfony-docs@dc9430a · GitHub
[go: up one dir, main page]

Skip to content

Commit dc9430a

Browse files
committed
drop varnish 2 example from varnish cookbook article
1 parent 9ea3671 commit dc9430a

File tree

2 files changed

+0
-29
lines changed

2 files changed

+0
-29
lines changed

conf.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,12 +101,10 @@
101101
lexers['php-annotations'] = PhpLexer(startinline=True)
102102
lexers['php-standalone'] = PhpLexer(startinline=True)
103103
lexers['php-symfony'] = PhpLexer(startinline=True)
104-
lexers['varnish2'] = CLexer()
105104
lexers['varnish3'] = CLexer()
106105
lexers['varnish4'] = CLexer()
107106

108107
config_block = {
109-
'varnish2': 'Varnish 2',
110108
'varnish3': 'Varnish 3',
111109
'varnish4': 'Varnish 4'
112110
}

cookbook/cache/varnish.rst

Lines changed: 0 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -83,17 +83,6 @@ configuration if you are still using Varnish 3:
8383
}
8484
}
8585
86-
.. code-block:: varnish2
87-
88-
sub vcl_fetch {
89-
// By default, Varnish2 ignores Pragma: nocache and Cache-Control: no-cache and private
90-
if (beresp.http.Cache-Control ~ "no-cache" ||
91-
beresp.http.Cache-Control ~ "private"
92-
) {
93-
return (hit_for_pass);
94-
}
95-
}
96-
9786
Enable Edge Side Includes (ESI)
9887
-------------------------------
9988

@@ -151,22 +140,6 @@ Symfony adds automatically:
151140
}
152141
}
153142
154-
.. code-block:: varnish2
155-
156-
sub vcl_fetch {
157-
// Check for ESI acknowledgement and remove Surrogate-Control header
158-
if (beresp.http.Surrogate-Control ~ "ESI/1.0") {
159-
unset beresp.http.Surrogate-Control;
160-
esi;
161-
}
162-
}
163-
164-
.. caution::
165-
166-
Compression with ESI was not supported in Varnish until version 3.0
167-
(read `GZIP and Varnish`_). If you're not using Varnish 3.0, put a web
168-
server in front of Varnish to perform the compression.
169-
170143
.. tip::
171144

172145
If you followed the advice about ensuring a consistent caching

0 commit comments

Comments
 (0)
0