Skip to content

Commit e3c7c66

Browse files
committed
Merge branch '8.0' into 8.1
* 8.0: Minor tweak Clarify `#[Cache]` attribute precedence behavior
2 parents 3feca27 + f4822be commit e3c7c66

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

http_cache.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -215,6 +215,11 @@ Thanks to this new code, your HTTP response will have the following header:
215215
216216
Cache-Control: public, maxage=3600, must-revalidate
217217
218+
.. tip::
219+
220+
When both are used, the cache headers defined in the controller take
221+
precedence over those configured with the ``#[Cache]`` attribute.
222+
218223
This tells your HTTP reverse proxy to cache this response for 3600 seconds. If *anyone*
219224
requests this URL again before 3600 seconds, your application *won't* be hit at all.
220225
If you're using the Symfony reverse proxy, look at the ``X-Symfony-Cache`` header

0 commit comments

Comments
 (0)