w3c / dx-connegp

Content Negotiation by Profile
https://w3c.github.io/dx-connegp/connegp/
Other
6 stars 5 forks source link

Explore whether Vary: headers are needed in responses for HTTP profile #38

Open rob-metalinkage opened 3 years ago

rob-metalinkage commented 3 years ago

Apparently dumb caches may need some help..

https://stackoverflow.com/questions/1975416/what-is-the-function-of-the-vary-accept-http-header

indicates a Vary:Accept-profile might be a necessary (SHOULD?) part of responses. Will need careful thought and testing about the case where a redirect to a static resource is supported.

YoucTagh commented 1 year ago

This will also be useful to third parties when Transparent CN style is adopted instead of Proactive CN or Reactive CN.

rob-metalinkage commented 8 months ago

@nicholascar to check implementation impact.

rob-metalinkage commented 8 months ago

@YoucTagh can you please comment on implementation potential if you think this is indeed useful.

YoucTagh commented 8 months ago

In my implementation I included the accept header when negotiating in the media type dimension, or the accept-profile header when negotiating in the profile one as indicated in the IETF document.

There is this study that explored HTTP header manipulation in-the-wild. Check the usage of vary header in Figure 1.

Also, while in the previous HTTP semantics RFC i.e. 7231, the section about the vary header was in the control data section, in the new one i.e. 9110 it is part of the content negotiation fields.