Skip to content

Support for multiple representations for a URL #112

@dasch

Description

@dasch

In some cases it makes sense to have multiple resources for the same URL, e.g. one for logged-in and one for anonymous users. I believe the spec supports this, as e.g. If-None-Match can contain a list of ETags.

I propose the following change:

  1. Rather than merely selecting the first matching cache entry for a request, get all matching entries.
  2. If one of them is still fresh, respond with that immediately.
  3. Otherwise – if they all need to be validated – collect the ETags and pass them all to the application in If-None-Match.
  4. If the application responds with 304, select the entry with the ETag found in the 304 response.

This would allow the application to control exactly what is returned to the client.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions