couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jason Davies <ja...@jasondavies.com>
Subject Re: %2F vs /
Date Wed, 14 Oct 2009 17:43:59 GMT
Hi Sven,

On 14/10/2009 18:34, Sven Helmberger wrote:

> There seem to have been multiple iterations how %2F is treated vs / in
> different access scenarios, with the current (0.10.0) behaviour seeming
> a little odd. First, there suddenly was a 301 response somewhere where
> it wasn't before. While accessing design documents, %2F using URLs get
> redirected to / ones which makes the new apache http client 4.0 java lib
> puke because it (rightfully, I think?) complains that it is receiving a
> redirect to the same URL which it interprets as endless loop thus being
> exception worthy.

We redirect /dbname/_design%2F/foo to /dbname/_design/foo.  These aren't 
the same URLs, so there shouldn't be an endless loop here, unless your 
library is prematurely decoding URL-encoded characters.

As for whether this is a good thing or not, I'm ambivalent at the 
moment.  I'm not 100% sure, but I think the main reason for 
special-casing design docs in this way was to make developing CouchApps 
easier (you can use ../app2 instead of ../../_design%2Fapp2).

Thanks,
--
Jason Davies

www.jasondavies.com

Mime
View raw message