[whatwg] Appcache feedback (various threads)

David John Burrowes bainong at davidjohnburrowes.com
Fri Aug 13 11:24:41 PDT 2010


On 2010/8/13, at 上午6:42, Anne van Kesteren wrote:

> On Fri, 13 Aug 2010 15:02:01 +0200, Patrick Mueller <pmuellr at muellerware.org> wrote:
>> On 8/12/10 6:29 PM, Ian Hickson wrote:
>>> On Thu, 29 Jul 2010, Anne van Kesteren wrote:
>>>> XML would be much too complex for what is needed. We could possibly
>>>> remove the media type check and resort to using the "CACHE MANIFEST"
>>>> identifier (i.e. "sniffing"), but the HTTP gods will get angry.
>>> 
>>> Yeah, that's pretty much the way it is.
>> 
>> Although I haven't personally had a problem dealing with the content-type requirement, I have heard from at least one other colleague who did; their server was harder to configure.
>> 
>> I had assumed the reason for having the specific text/cache-manifest content type was to force people to "opt-in" to support, instead of being able to just read a random URL and having it interpreted, perhaps maliciously, as a manifest.
>> 
>> If that's not a concern, then I'd like to understand the ramifications of getting the HTTP angry gods angry by ignoring the content-type.
> 
> In HTTP (starting HTTP/1.0), entity bodies are identified by the Content-Type header, not by themselves. We violate that for a number of scenarios, but we try to stay clear of it in new, until such time comes that we give up completely on Content-Type. It's a compromise.

I can understand wanting to do things right, in terms of using Content-Type for the file.  I can also attest that it can be a royal pain to diagnose when this is set wrong.  I wonder it it would make sense to have a recommended file extension for the manifest (e.g. "cachemanifest" so "myapp.cachemanifest"). (maybe "manifest" is a fine extension, as implied in the spec.  It seems a bit generic of a name to me, though). This way, web server developers could add this into their default configurations.

That is, life will be a lot easier for page developers in the future, if (say) apache ships with a rule that automatically delivers "cachemanifest" (or whatever) files with the text/cache-manifest content type.  That way everything will "just work" for normal situations.

David




More information about the whatwg mailing list