Commit 6150231
Guillaume Quintard
[vcl] don't set TTL to 0
Because of request coalescing, setting the TTL to 0s actually causes
backend request queueing, meaning that for one specific object,
Varnish will only allow one request at a time.
For Varnish 4, set the TTL to 2 minutes, leveraging Hit-for-Pass and
Varnish will transform any hit into a pass for the next 2 minutes,
preventing queueing.
For 5 and 6, the default mechanism is Hit-for-Miss, which works the same
as HfP with the added bonus that if the response changes and we we decide
to cache it, this will override the HfM TTL. So we can set the TTL for
one day.1 parent def5104 commit 6150231
File tree
3 files changed
+8
-12
lines changed- app/code/Magento/PageCache/etc
3 files changed
+8
-12
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
166 | 166 | | |
167 | 167 | | |
168 | 168 | | |
169 | | - | |
| 169 | + | |
170 | 170 | | |
171 | 171 | | |
172 | 172 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
166 | 166 | | |
167 | 167 | | |
168 | 168 | | |
169 | | - | |
170 | | - | |
171 | | - | |
172 | | - | |
173 | | - | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
174 | 172 | | |
175 | 173 | | |
176 | 174 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
165 | 165 | | |
166 | 166 | | |
167 | 167 | | |
168 | | - | |
169 | | - | |
170 | | - | |
171 | | - | |
172 | | - | |
173 | | - | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
174 | 172 | | |
175 | 173 | | |
176 | 174 | | |
| |||
0 commit comments