couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Davis <paul.joseph.da...@gmail.com>
Subject Re: Documents with many attachments
Date Fri, 04 Dec 2009 03:57:14 GMT
On Thu, Dec 3, 2009 at 10:43 PM, Chris Anderson <jchris@apache.org> wrote:
> On Thu, Dec 3, 2009 at 5:48 PM, Dave Ray <daveray@gmail.com> wrote:
>> Hi there,
>>
>> Is there any reason in terms of performance, stability, or good taste,
>> that I should avoid adding 100s or 1000s of attachments to a document?
>> I have about 3000 pngs on a document and things seem to work fine
>> (aside from Futon being a little unusable when I view the doc), but if
>> this is going to cause me trouble later I can split it up into
>> multiple docs with single attachments without much more work. Just
>> wondering.
>
> At a certain point, you could have too many, and that would start to
> suck. Since they are all in one doc the metadata for the attachments
> has to fit in memory.
>
> Probably the best metric you can have is the size of the JSON stubs
> you're schlepping around on the doc. With 100k attachments the JSON
> doc would be too big to deal with. Maybe you can handle all the JSON
> for 10k attachments -- a doc with one thousand attachments is not that
> many kb of JSON.
>

There's also one of the replication directions. I don't remember
which, but one of them doesn't like having lots or large attachments.
This might be changing as we got to a multipart mime format, but for
0.10.x or before the issue exists.

Paul Davis

Mime
View raw message