Re: content negotiation anti-principle

On Tuesday 31 December 2002 01:29 pm, Simon St.Laurent wrote:
> It seems like the principle that emerges from these many varied
> specifications - and this perhaps perverse reading of them - is that
> content negotiation, while maybe something that can and does happen on
> the Web, is not something that is actually integral to specifications
> intended for client-side processing. Servers do weird things, and the
> best way to handle this is to just let it go.  HTTP 1.1's
> content-negotiation features (and the philosophical disconnect between
> resources and representations) are not actually central to the operation
> of the Web.

FWIW. I tend to agree with this. Content negotiation has complicated things in 
many different ways.... and in many cases, URL partitioning makes much more 
sense.

A good example comes from I18N. I've always been in favor of using content 
negotiation for language selection of resources. For example, going to:

   http://www.foo.com/index.html

would give you an English page if your Accept-* headers indicate that's your 
preference and Japanese if that's your preference. I built such functionality 
into a number of systems, but in practice people used redirects and URL 
partitioning, even when they had an alternative. 

In retrospect, I think the approach I favored is wrong in many cases. The 
reason people use URL partitioning is because it makes sense to them, and has 
some meaning. The same thing can be said of any URI which, because of it's 
structure, has some semantics to the things interpreting them. 

Perhaps the real problem is that there's no easy way to force a particular 
representation to be returned? Content negotiation is at a lower level than 
remembered URL's, so there's some "gap" between the implied semantics and the 
actual protocol.

Received on Sunday, 5 January 2003 09:16:31 UTC