Skip to content

Commit

Permalink
Merge pull request #155 from FriendsOfSymfony/remove-duplicated-vcl
Browse files Browse the repository at this point in the history
remove duplicated line from varnish 3 vcl
  • Loading branch information
dbu committed Jan 17, 2015
2 parents 42af71c + 4654017 commit 8da5db9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
4 changes: 2 additions & 2 deletions doc/varnish-configuration.rst
Original file line number Diff line number Diff line change
Expand Up @@ -124,13 +124,13 @@ to the ``recv`` and the ``deliver`` methods:

.. literalinclude:: ../tests/Functional/Fixtures/varnish-3/user_context.vcl
:language: varnish3
:lines: 1-28, 32-
:lines: 1-27, 31-
:linenos:

.. sidebar:: Caching User Specific Content

By default, Varnish does not check for cached data as soon as the request
has a ``Cookie`` or ``Authorization`` header, as per the `builtin VCL`_
has a ``Cookie`` or ``Authorization`` header, as per the `builtin VCL`_
(for Varnish 3, see `default VCL`_). For the user context, you make Varnish
cache even when there are credentials present.

Expand Down
3 changes: 1 addition & 2 deletions tests/Functional/Fixtures/varnish-3/user_context.vcl
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ sub vcl_recv {
&& (req.http.cookie || req.http.authorization)
&& (req.request == "GET" || req.request == "HEAD")
) {
set req.http.x-fos-original-url = req.url;
# Backup accept header, if set
if (req.http.accept) {
set req.http.x-fos-original-accept = req.http.accept;
Expand All @@ -26,7 +25,7 @@ sub vcl_recv {
# Backup original URL
set req.http.x-fos-original-url = req.url;
set req.url = "/user_context_hash.php";

# For functional tests
call user_context_hash_url;

Expand Down

0 comments on commit 8da5db9

Please sign in to comment.