Return-Path: Delivered-To: apmail-couchdb-dev-archive@www.apache.org Received: (qmail 4529 invoked from network); 26 Feb 2009 15:47:54 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 26 Feb 2009 15:47:54 -0000 Received: (qmail 75489 invoked by uid 500); 26 Feb 2009 15:47:53 -0000 Delivered-To: apmail-couchdb-dev-archive@couchdb.apache.org Received: (qmail 75458 invoked by uid 500); 26 Feb 2009 15:47:53 -0000 Mailing-List: contact dev-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@couchdb.apache.org Delivered-To: mailing list dev@couchdb.apache.org Received: (qmail 75447 invoked by uid 99); 26 Feb 2009 15:47:53 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 26 Feb 2009 07:47:53 -0800 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of paul.joseph.davis@gmail.com designates 209.85.217.162 as permitted sender) Received: from [209.85.217.162] (HELO mail-gx0-f162.google.com) (209.85.217.162) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 26 Feb 2009 15:47:46 +0000 Received: by gxk6 with SMTP id 6so1443397gxk.11 for ; Thu, 26 Feb 2009 07:47:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=8v67zQIZaDcQTf/sIIVHImkHBdDtZvwbjU51YxW4sfQ=; b=sZm7TXkX/XG+mfoIzDUv7YjbqJ/UNP97j43mB2B2lGjRA8JrTX7v79pJogQ+0BY9Xm fQWbD9z1MtviCWq/H6r4GhsNe0QKQ8vWzrv2I2CbPmPCyQor104aPQiSSC1NHpQT7PxF JFvL13m7T03oXK5NPOeNZeUx1iI0pqJUksbNY= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=uSv4T7AF1y5hwTif7YPHE/1w9E9XaN4/atqKvwg8u7U8/aMdTtOT7WzJA+RnturtJw vXyycFx1BLRolcV7c8cJdvD4rezj6tK/iH1B8qSnnfFgq31gk/rjhzFPK2a3iDXyAW17 mfIBHVVyyS+B4Ze5ODYAsMM4zz2jkfW4bOWgc= MIME-Version: 1.0 Received: by 10.100.41.9 with SMTP id o9mr1626553ano.39.1235663233943; Thu, 26 Feb 2009 07:47:13 -0800 (PST) In-Reply-To: <5aaed53f0902260542k1bbefecbt3bf4e732bc79589@mail.gmail.com> References: <5aaed53f0902250507t47edbef3ra43a7e4761d6d5dc@mail.gmail.com> <20090226080342.GA6356@uk.tiscali.com> <42D5E435-4453-46B2-98B9-0AA3439C3FCB@apache.org> <5aaed53f0902260542k1bbefecbt3bf4e732bc79589@mail.gmail.com> Date: Thu, 26 Feb 2009 10:47:13 -0500 Message-ID: Subject: Re: [RESULT]: Accept newline patch into CouchDB for 0.9 (Was: Re: VOTE: accept newline patch into CouchDB for 0.9) From: Paul Davis To: dev@couchdb.apache.org, tech@dundeemt.com Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org On Thu, Feb 26, 2009 at 8:42 AM, Jeff Hinrichs - DM&T wrote: > On Thu, Feb 26, 2009 at 3:56 AM, Jan Lehnardt wrote: >> >> On 26 Feb 2009, at 09:03, Brian Candler wrote: >> >>> On Wed, Feb 25, 2009 at 07:07:11AM -0600, Jeff Hinrichs - DM&T wrote: >>>>> >>>>> CouchDB dodges this at present, since you can't download a document >>>>> together >>>>> with its attachments. >>>> >>>> what about ?attachments=3Dtrue =A0or am I misunderstanding you? >>> >>> This is new to me - such feature doesn't seem to be mentioned at >>> http://wiki.apache.org/couchdb/HTTP_Document_API, where it says: >>> >>> "When retrieving documents, the attachment's actual data is not include= d, >>> only the metadata. The actual data has to be fetched separately, using = a >>> special URI." >>> >>> However I do see "attachments=3Dtrue" in couch_rep.erl. Is this somethi= ng >>> internal/private for replication? >> >> This is an omission in the documentation. I added it to the wiki now wit= h >> a note that you should not use it :) I think the plan forward is to add = an >> API >> where documents and attachments can be transferred in a single HTTP >> request using a multipart mime request. This will speed up replication, > Not immediately apparent that this is true, only if mime encode/decode > is faster than json encode/decode > The major speed up factors when doing this in multipart mime are: 1. Streaming bytes from and to disk for attachments. 2. No Base64 round trip 3. No base64 means less data transferred Seems like I'm missing another one, but those are the biggies. HTH, Paul Davis >> fix handling replication with large attachments and makes it possible to >> create a document and a set of attachments without going through >> intermediate revisions. > I am doing this currently, the recent fix to mochiweb of the 1MB body > regression allows one to upload document + attachments in a single > revision -- you need to base64 the attachment and set the attributes, > but it works. =A0My dump/load code does it quite nicely. >> > > Regards, > > Jeff Hinrichs >