incubator-couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brian Candler <>
Subject Re: I need to know how to parse attachment data
Date Tue, 26 May 2009 07:59:27 GMT
On Mon, May 25, 2009 at 12:07:55PM +0800, Darrell Huang wrote:
> Hi, everyone, I got some trouble in reading the attachment data from  
> documents with the HTTP API. When an attachment is downloaded with the 
> API, some extra data is found before and after the attachment data, and 
> the data can be different at different times.
> For example, when I downloaded an attachment with the jpg format several  
> weeks ago, there is a character sequence "dbc\r\n" preceding the actual 
> file data, but when I did that today, it was "a24\r\n".

That would be HTTP chunking, wouldn't it? If you send a request advertising
HTTP/1.1 capability, then you are required to accept
Transfer-Encoding: Chunked
in the response.



View raw message