Skip to content

Compress plugin should send always Vary: accept-encoding if content-type matches #7003

Description

@mlibbey

When a request comes to a remap that has the compress plugin, but does not have an Accept-encoding: header that indicates the plugin should compress, but, the object would otherwise be compressible we should still add a Vary: accept-encoding.

Say an ATS close to the origin in a cache hierarchy (a parent) receives a request that does not ask for compression on a compressible object. It responds, and, because the response does not have Vary: accept-encoding, an ATS closer to the client (child) think that it is the only possible variant. For the next request that does ask for compression, that 1st ATS in the path will have a cache hit for the uncompressed object and send it uncompressed.

If however the parent originally sends Vary: accept-encoding, the child can still ask the parent for the compressed version.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions