couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sho Fukamachi <>
Subject Re: Write metadata inside _attachments?
Date Wed, 18 Feb 2009 14:19:40 GMT
Thanks for the reply Jan. Issue created:

Yes, I am also currently solving the problem by maintaining a separate  
object as well, but feel it's a little messy and overly complex. I had  
thought it wouldn't be too hard, as the content_type is being stored  
there already, isn't it? I don't know enough about the internals,  
though, so that could be completely wrong.

thanks again,


On 18/02/2009, at 9:00 PM, Jan Lehnardt wrote:

> On 18 Feb 2009, at 10:45, Sho Fukamachi wrote:
>> Hi Couchists,
>> Having in some cases multiple attachments per document, I would  
>> like to be able to store some metadata next to each attachment -  
>> the width/height of a picture, for example, or the bitrate of an  
>> mp3. Obviously it would be nice if I could do it in the same place  
>> as the MIME type, byte size, etc. However, I can't find any way to  
>> get data in there.
>> Is this possible / desirable / should I be doing something else?
> This is not currently possible but I think this sounds interesting.
> It came up with CouchApp where we want to store checksums
> with the files (although this feature is no longer needed with per-
> attachment ETags). hmm. I'm worrying a bit about the underlying
> data storage changes. This would effectively a document within
> a document and I don't know how flexible the attachment meta
> data store is.
> CouchApp solves this now by maintaining a mirrored sub-object
> in the main document that it syncs with the _attachments structure.
> While not really neat, it can be fully automated and put into a  
> library.
> Can you open a issue on JIRA for this so we can discuss this
> on dev@?
> Cheers
> Jan
> --

View raw message