Closed (won't fix)
Project:
ESI: Edge Side Includes
Version:
7.x-3.0-alpha1
Component:
Documentation
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
14 May 2013 at 13:56 UTC
Updated:
23 Jul 2019 at 09:06 UTC
Jump to comment: Most recent
Comments
Comment #1
mike.roberts commentedDid it refresh after 4 minutes? My guess is that your Page Cache for auth users is trumping your block ESI.
Edit: I meant anonymous users, not authenticated. Varnish is caching the entire page html for 4 minutes, and your block probably isn't actually getting cached through ESI at all. Not sure if you can have varnish page cache + ESI through varnish on the same page without some sort of conflict.
Comment #2
gregglesPer #1.
Comment #3
robit8deb commentedIve tried adding the default vcl code and i can never get it to start. I even tried added the ; as the compiler suggest but that does not work. Varnish starts without issue without the esi code.
Here is the error:
Message from VCC-compiler:
Expected ';' got 'esi'
(program line 174), at
('input' Line 259 Pos 16)
esi;
---------------###-
Running VCC-compiler failed, exit 1
VCL compilation failed
Here this the full section pasted from the text file example
sub vcl_recv {
call esi_block__recv;
}
sub vcl_hash {
call esi_block__hash;
}
sub vcl_fetch {
# don't ESI anything with a 3/4 letter extension
# (e.g. don't try to ESI images, css, etc).
if (! req.url ~ "\..{3,4}$") {
set beresp.do_esi = true
esi; #<----LINE 259
}
call esi_block__fetch;
}
Comment #4
yannisc commentedSame problem here. Did you find any solution?
Comment #6
robinmofo commentedIn response to #3, the answer was found in the varnish website
Varnish Site
This is for Varnish 3:
set beresp.do_esi = trueThis is for Varnish 2:
esi; #<----LINE 259Comment #7
dstuart commented