Re: Cool URIs MIME types

Peter,

On 24 Jul 2008, at 22:40, Peter Ansell wrote:
> I may be confused, but under the 303 redirect model are you allowed to
> do multiple redirects.

First, you seem to assume that content negotiation requires redirects.  
That's not the case. Content negotiation is typically done *without*  
any redirection, by serving the appropriate variant directly with a  
200 OK (e.g. at <http://example.com/foo>), and by adding a Content- 
Location header that points to a URI specifically for the variant  
(e.g. <http://example.com/foo.html> or <http://example.com/foo.rdf>).

That being said:

> I know that under the HTTP standard you can do
> as many redirects as needed provided a user agent is willing to follow
> them all. but if the 303 is supposed to point from a
> pseudo-real-resource URI to an information-resource then does it
> chain?

Here you seem to assume that 303 redirects carry semantics such as  
“the origin MUST be a non-information resource” or “the destination  
MUST contain a description of the origin”. But that is simply not  
true. It's a frequent misunderstanding.

The 303 technique is just a way of continuing the HTTP conversation in  
situations where the server for some reason will not give you a  
representation of the resource.

So, the semantics of a 303 redirects are: “the server won't or can't  
give you a representation of the origin resource (for whatever  
reason)” and “in the origin server's opinion, the destination resource  
is somehow relevant”.

These are very weak semantics. There is nothing in them that is  
inconsistent with multiple redirects.

But again, as I said above, adding more content-negotiated variants to  
your documents doesn't require more redirects.

> If it does then dealing with those extra mime types would just
> be an issue for the application. Ie, replace application/rdf+xml in
> the document with your favourite format and see if you get something
> suitable back, else try again with your second-favourite format etc.
>
> I think the "cool" thing about the URI's is that they don't require
> the format to be a particular value inately, although it would be nice
> if the resulting format that comes back the first time has links
> directly to the other formats. ie, HTML with link rel=alternate etc to
> avoid guessing which formats are available.

+1 for listing all available formats using rel="alternate".

Best,
Richard


>
>
> Cheers,
>
> Peter
>
> PS. Maybe I missed something also!
>

Received on Friday, 25 July 2008 09:35:32 UTC