File tree Expand file tree Collapse file tree 2 files changed +18
-0
lines changed Expand file tree Collapse file tree 2 files changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -37,6 +37,19 @@ These five steps resemble the Overview in the FOSHttpCache documentation.
3737 sets a ``Vary: X-User-Context-Hash `` header. The appropriate user context
3838 dependent representation of ``/foo `` will then be returned to the client.
3939
40+ .. note ::
41+
42+ In other words we execute a preflight request here. A preflight request is
43+ a request that is sent prior to the real request. See for example how
44+ `CORS requests `_ work. The result of the preflight request is the
45+ ``X-User-Context-Hash `` header that is added to the real request.
46+
47+ This concept can be generalized to handle more than the user context
48+ scenario. The `terminal42/header-replay-bundle `_ builds on top of the
49+ ``FOSHttpCacheBundle `` to add support for more complicated use cases. Have
50+ a look at the `HeaderReplayBundle documentation `_ if the user context is
51+ not flexible enough for your needs.
52+
4053Configuration
4154-------------
4255
@@ -111,3 +124,7 @@ Caching Hash Responses
111124
112125To improve User Context Caching performance, you should cache the hash responses.
113126You can do so by configuring :ref: `hash_cache_ttl `.
127+
128+ .. _CORS requests : https://developer.mozilla.org/en-US/docs/Web/HTTP/Access_control_CORS
129+ .. _terminal42/header-replay-bundle : https://github.com/terminal42/header-replay-bundle
130+ .. _HeaderReplayBundle documentation : https://github.com/terminal42/header-replay-bundle#terminal42header-replay-bundle
Original file line number Diff line number Diff line change 1818login
1919logout
2020Packagist
21+ preflight
You can’t perform that action at this time.
0 commit comments