You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Automatically compress responses from Accept-Encoding #111
Provide automatic response compression negotiated from the client Accept-Encoding, without requiring applications to write or manually assemble compression middleware.
Main has gzip/Brotli decoding helpers, but no response encoder/negotiation middleware in the public core surface. PR #452 proposes explicit Fastly delivery-compression intent; applications still own reader negotiation/fallback, so it covers only part of this story.
Steps to reproduce
Inspect the compression module and middleware module for an outgoing compression policy.
An application can enable a supported automatic policy and receive an encoding acceptable to the client with consistent response metadata.
Impact
Applications currently implement negotiation and compression policy themselves, limiting portability and increasing integration work.
Proposed fix
Design a small configuration/adapter integration over supported encoders, including safe identity fallback, encoded-body preservation and streaming behavior. Reuse #452 where applicable without equating explicit intent with automatic negotiation.
Done when
Automatic selection honors supported Accept-Encoding values and quality/identity behavior.
Headers such as Content-Encoding, length and Vary match the emitted bytes, including already encoded responses.
Bodyless/otherwise ineligible responses are handled correctly and streaming behavior is documented.
An example enables the behavior without custom compression middleware code.
changed the title [-]As a developer I want automatic response compression[/-][+]Automatically compress responses from Accept-Encoding[/+]on Nov 9, 2026
Activity
[-]As a developer I want automatic response compression[/-][+]Automatically compress responses from Accept-Encoding[/+]