Return-Path: Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: (qmail 50367 invoked from network); 26 Sep 2009 07:22:43 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 26 Sep 2009 07:22:43 -0000 Received: (qmail 85355 invoked by uid 500); 26 Sep 2009 07:22:42 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 85319 invoked by uid 500); 26 Sep 2009 07:22:42 -0000 Mailing-List: contact user-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@couchdb.apache.org Delivered-To: mailing list user@couchdb.apache.org Received: (qmail 85309 invoked by uid 99); 26 Sep 2009 07:22:42 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 26 Sep 2009 07:22:42 +0000 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 jchris@gmail.com designates 209.85.222.182 as permitted sender) Received: from [209.85.222.182] (HELO mail-pz0-f182.google.com) (209.85.222.182) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 26 Sep 2009 07:22:32 +0000 Received: by pzk12 with SMTP id 12so1175492pzk.13 for ; Sat, 26 Sep 2009 00:22:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:sender:received:in-reply-to :references:date:x-google-sender-auth:message-id:subject:from:to :content-type:content-transfer-encoding; bh=b9HjG/WqhbuN+abNkiI2Bp8zFYE+3nvjrQQl0Xowslw=; b=nn77lEwPmG3GPg4ZpRfPW7bk0ndiNs2ZpTx7Wdokly7pgpHfMDf83PmWVp+dm3tO0c A7yu+9qHYUWQi79xv8z995s9/bfApq37RZpRskhAFk0R5KPX1sEj8u6ySQNG83nMaH0g MDjIa3KMHo62OcZXvvW+m930ltrvIO390hO4g= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:content-type :content-transfer-encoding; b=wdv+JBFEyYxF3a0oymnpet76mzhN7Y8UMQRbS3SY/aKf2OzO7Jk/f7dVZ6iil6vYsZ V1+OZuKBPzQcmpG+VwJuvJ7HJwK4EDFDsunrlAwccHDhkpNclwLtYkyZHa2GnyEfHWYh fT8CSNp3nVLt5NvLSxg28zyCFtMnFtIcBbp8w= MIME-Version: 1.0 Sender: jchris@gmail.com Received: by 10.142.248.41 with SMTP id v41mr78690wfh.284.1253949732015; Sat, 26 Sep 2009 00:22:12 -0700 (PDT) In-Reply-To: <882214.95805.qm@web45315.mail.sp1.yahoo.com> References: <796695.24188.qm@web45314.mail.sp1.yahoo.com> <8a02878f0909251832n3358d3b3s4d0dfe4513917500@mail.gmail.com> <8a02878f0909251839g655b83aak3bd01ee753dc2cac@mail.gmail.com> <882214.95805.qm@web45315.mail.sp1.yahoo.com> Date: Sat, 26 Sep 2009 00:22:11 -0700 X-Google-Sender-Auth: 5202c394a80c107f Message-ID: Subject: Re: couchdb: suitable for this type of applications ? From: Chris Anderson To: user@couchdb.apache.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org On Fri, Sep 25, 2009 at 8:34 PM, go canal wrote: >>>When you compact the database it removes all but the most recent version= of each document. > > > Does this mean that if I want to support document version feature, I can = not compact the database ? > Applications should not depend on controlling compaction schedules. Only the most recent version is replicated, so if you run in a cluster it's like it's compacting all the time. > Let's say I am working on a Word document, I upload it as an attachment; = I need to have a list of all versions for this file and can download any of= previous version. > > Is this how I should model it in CouchDB: > =A0- have a version field, not using the CouchDB _rev. update the version= in my application. > =A0- when uploading the modified Word document, a doc with a different ID= is created. So compacting a DB will not affect them. > =A0 =A0but how to get a list of all versions of this document ? I need to= use another field to identify them, for example, another application gener= ated ID. > > Is this the general practice ? I am sure supporting versioning is a commo= n request, so appreciate if you can provide some advices.. > thanks, > canal > > > --=20 Chris Anderson http://jchrisa.net http://couch.io