Return-Path: Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: (qmail 77518 invoked from network); 26 May 2009 07:52:29 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 26 May 2009 07:52:29 -0000 Received: (qmail 60747 invoked by uid 500); 26 May 2009 07:52:41 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 60579 invoked by uid 500); 26 May 2009 07:52:41 -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 60502 invoked by uid 99); 26 May 2009 07:52:41 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 26 May 2009 07:52:41 +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 jurgvanvliet@gmail.com designates 209.85.219.168 as permitted sender) Received: from [209.85.219.168] (HELO mail-ew0-f168.google.com) (209.85.219.168) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 26 May 2009 07:52:32 +0000 Received: by ewy12 with SMTP id 12so4140628ewy.11 for ; Tue, 26 May 2009 00:52:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:cc:message-id:from:to :in-reply-to:content-type:content-transfer-encoding:mime-version :subject:date:references:x-mailer; bh=Ch3y3T29GUyS66fQs4xtyDFzOmeo90lmcpPRqQrmsY8=; b=eqFyio3D9T/YjJoxfmn5QNH3m8iyb+S22F/6Oc7B+j+HrCXDlBkmYDRBBSD6J0yahJ PgmEbyViww302ctEp0knW+HW9O0Ag4p7WmJSBwxUHuLnUhgPToBId9lBZne1r94rqFU4 NU+041a7ZJImHXdY1+BB1avqvI2pNB6RyabBQ= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=cc:message-id:from:to:in-reply-to:content-type :content-transfer-encoding:mime-version:subject:date:references :x-mailer; b=HMSJH9qZf58bP6JqvX1JpjxTNua0qqG92k7Njn3iU5VIx5EbKoRFEqw47rXHufkQp0 fTQlFHexXVlg413VknvpEdy9itMRBrBcJh3KA7/gF21CEDwNsJfxEe7T4J+yUS00O7ev ZDWIbNZWrGD2p3tQNv2eTPF+96Hh8v9J6oKlE= Received: by 10.216.3.206 with SMTP id 56mr2984746weh.99.1243324329932; Tue, 26 May 2009 00:52:09 -0700 (PDT) Received: from Truthtrap.lan (a82-95-195-249.adsl.xs4all.nl [82.95.195.249]) by mx.google.com with ESMTPS id 5sm6059310eyh.40.2009.05.26.00.52.08 (version=TLSv1/SSLv3 cipher=RC4-MD5); Tue, 26 May 2009 00:52:09 -0700 (PDT) Cc: user@couchdb.apache.org Message-Id: <4224356C-78BF-465D-BFC0-8F32601D3CB6@gmail.com> From: Jurg van Vliet To: dev@couchdb.apache.org In-Reply-To: <20090526073946.GA9022@uk.tiscali.com> Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Apple Message framework v935.3) Subject: Re: struggling with couchdb in production Date: Tue, 26 May 2009 09:52:08 +0200 References: <20090526073946.GA9022@uk.tiscali.com> X-Mailer: Apple Mail (2.935.3) X-Virus-Checked: Checked by ClamAV on apache.org On May 26, 2009, at 9:39 AM, Brian Candler wrote: > On Mon, May 25, 2009 at 12:36:11PM -0700, Chris Anderson wrote: >>> a database in couchdb is the place where work comes together, in >>> our case >>> this is the location where a group of people shares. combining >>> information >>> from different databases will be necessary. and i really have no >>> clue yet >>> how to approach this problem. so anyone? >> >> The easiest thing is to merge the databases with replication. > > In some ways this is the easiest - and in some ways it is the hardest. > > It will be easy if your various sources are creating distinct > documents. It > will be hard if the various sources are editing the same documents - > because > you will start having to deal with replication conflicts. i think replication is not the solution for the specific problem i tried to sketch. i am talking about simple aggregate information (10 most recent documents per user, for example) over potentially thousands of different databases. if i have to replicate all my databases into one big database i would start with a big one and replicate out to handle load. that feels like 'missing the point'. (though i am still struggling which point exactly :) ) > > > Whilst CouchDB's model for this is logically self-consistent, I > personally > still believe that it's difficult to use for real-world > applications. For > example, if you GET a document, you will get one arbitrary version. > You will > get no indication that conflicting versions of this document may or > may not > exist. If you want to ensure that your user always sees the latest, > resolved > version of the document, then you need to explicitly ask for all the > conflicting revisions, and then you need to fetch them individually > (AFAICS, > even a regular "bulk fetch" using _all_docs and keys can't do this), > and > then merge them in an application-specific way, and then put back > the merged > version and delete all the conflicting revs. yes and no, it all depends on how you regard your users. i think in an environment where many people create something together the conflicts have meaning. i choose to expose the conflict, meaningfully, and 'help' the user resolve it herself. but this is different from what we have been taught. we are all a bit afraid of difficult and critical users, because we might have to explain why things break :P i do feel it fits very well with couchdb though. in an environment where the conflicts are not results of user actions there is no problem as well, because the conflicts are logical. (not necessarily the same as meaningful, though :P ) groet, jurg. > > > Regards, > > Brian.