Skip to content

CacheFilter: Fully parse and handle request and response cache-control #9833

@toddmgreer

Description

@toddmgreer

The cache-control header (RFC7234§5.2) supports a long list of directives, all of which need to be understood by CacheFilter (#7198). Currently, CacheFilter only parses and handles the private, no-cache, max-age, and s-maxage response directives, and ignores the rest. Some directives (max-stale, min-fresh, no-transform, only-if-cached, must-revalidate, public, proxy-revalidate), cause no harm (other than missed caching opportunities) if ignored. Others (max-age and no-cache request directives, and no-store request/response directive) can cause incorrect results to be served, and thus must be handled before CacheFilter can be generally usable with production traffic.

Current parsing code is in extensions/filters/http/cache/http_cache_utils.cc and cache_filter.cc.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions