On Thu, May 26, 2016 at 5:29 PM, Pinakee BIswas <[email protected]> wrote:
> We have been planning to replace nginx caching with Varnish and use nginx > purely as a proxy. For some requests, we plan to bypass Varnish as they > need not be cached. Also, we are serving static content using nginx. > Once this is sorted, I'd rather use varnish as a proxy, but, that's just me :-) > To answer your query, it works fine without varnish. I have tested > removing varnish and then adding it. I also, was surprised that it wasn't > working properly as the logs say otherwise. Will investigate further. > Please do, the logs aren't showing anything weird. Note one thing: varnish will automatically add the X-Varnish header and put the VXID of the request (in case of a MIS/PASS) and the of the bereq (for a HIT), so when you get a wrong object, you can look a the varnishlog (using "-d" to look at past records), possibly filtering it with "-q" and check what was the cached request. One more thing, for the unlogged user, it seems your backend is replying with a set-cookie header. I don't think it's necessary. One more thing is the cookie in the request log isn't showing all the > cookies: > > - ReqHeader Cookie: > _xsrf=2|f25d8caf|ffacf1c86b71827915f94aed8e9aeace|1462920275; > jivaana_country=IN; pagemap=0,0,0,0,0,1,0'; > mp_774636c1ed2371eaf99455f71871069c_mixpanel=%7B%22distinct_id%22%3A%20%221518b8ba6c314b-04bd3d4-6b1b237b-100200-1518b8ba6c428a%22%2C%22%24i > That's expected, varnish will truncate long log records, you can change vsl_reclen to see longer lines in the log. It doesn't change what actually goes on the wire. -- Guillaume Quintard
_______________________________________________ varnish-misc mailing list [email protected] https://www.varnish-cache.org/lists/mailman/listinfo/varnish-misc
