vary header important

2008-01-02 @ 17:58#

today i stumbled upon a nice post from subbu on the Vary header. good stuff.

i'd been dealing with this last month as i cleaned up support for multiple representations in my exyus engine. doing mime-type content negotiation is (IMHO) essential for REST-compliant applications. and, given the state of browser clients out there (the bulk of the REST clients[?]), i think server-side conn-neg for mime-types is the best way to go. smart clients and take full control and browsers can get the default mime-type unless their Accept header refuses to accept it. all cool.

but then you have to deal with caches. and that means using the Vary header properly. too bad, as is pointed out in the post, that MSIE has a hard time with the Vary header when it comes to caching. sounds like any request that has a Vary is just not cached locally my MISE. well, that's safe, if not efficient.

code