couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Samuel <samuelri...@gmail.com>
Subject database names containing +
Date Tue, 07 Sep 2010 16:27:58 GMT
Hi,

couchdb is reporting an error if I try to create or delete a database
with a "+" in its name:

PUT /a+ HTTP/1.1
Content-Type:application/json
Content-Length:0
Host:localhost:5984

HTTP/1.1 400 Bad Request
Server: CouchDB/1.1.0a4875101-git (Erlang OTP/R14B)
Date: Tue, 07 Sep 2010 16:04:37 GMT
Content-Type: text/plain;charset=utf-8
Content-Length: 181
Cache-Control: must-revalidate

{"error":"illegal_database_name","reason":"Only lowercase characters
(a-z), digits (0-9), and any of the characters _, $, (, ), +, -, and /
are allowed. Must begin with a letter."}

Encoding it works, though:

PUT /a%2B HTTP/1.1
Content-Type:application/json
Content-Length:0
Host:localhost:5984

HTTP/1.1 201 Created
Server: CouchDB/1.1.0a4875101-git (Erlang OTP/R14B)
Location: http://localhost:5984/a%2B
Date: Tue, 07 Sep 2010 16:25:38 GMT
Content-Type: text/plain;charset=utf-8
Content-Length: 12
Cache-Control: must-revalidate

{"ok":true}

Is the + symbol special for some reason? Any other character seem to
work without encoding?

Cheers
-- 
Samuel

Mime
View raw message