Skip to content

@cache: opt-in X-Cache: HIT/MISS debug header #335

Description

@allen0099

Problem

A new user cannot tell a hit from a miss without adding counters to their handlers. The only signal is DEBUG logging.

Proposal

Add an opt-in debug header (e.g. @cache(..., debug_header=True) or a global setting) that sends X-Cache: HIT | MISS | BYPASS | STALE. Keep it off by default, since it reveals caching behaviour to clients.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    developer-experienceSurprising behaviour, missing warnings or unclear errors for library usersenhancementNew feature or requesthttp-cacheThe @cache decorator, cache keys and Cache-Control handling

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions