Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
4.1.x sometimes duplicates Age and Accept-Ranges headers #1955
With Varnish 4.1.x in a production configuration that layers multiple varnish caches requesting from other varnish caches, in the final output we often see duplicate (or even triplicate)
Relatedly, we backported d828a04 into our 4.1.x package, and this did seem to resolve the issue for 304 refreshes of stale objects, but not for the general case.
Expect only 1 copy each of
Seeing 2-3x of these headers headers sent to client, one for each layer of Varnish cache the request passes through. They seem to always have identical values, at least in short-TTL cases, but this may be mostly a coincidence.
Steps to Reproduce (for bugs)
Live example: https://maps.wikimedia.org/ (2-4 layers of varnish caching, depending where you are geographically).
I am working on this now, but I can't reproduce the problem. I have tried the realeases 4.1.1 and 4.1.2, as well as the 4.1 and master branches.
I can see you problem in your live example, but it would be very helpful to have a minimal example (preferably varnishtest) on my own computer where multiple Age headers appear.
I will try again tomorrow.