Return-Path: Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: (qmail 60265 invoked from network); 5 Jan 2010 18:45:47 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 5 Jan 2010 18:45:47 -0000 Received: (qmail 38522 invoked by uid 500); 5 Jan 2010 18:45:45 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 38467 invoked by uid 500); 5 Jan 2010 18:45:44 -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 38412 invoked by uid 99); 5 Jan 2010 18:45:44 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 05 Jan 2010 18:45:44 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of gcdcu-couchdb-user@m.gmane.org designates 80.91.229.12 as permitted sender) Received: from [80.91.229.12] (HELO lo.gmane.org) (80.91.229.12) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 05 Jan 2010 18:45:35 +0000 Received: from list by lo.gmane.org with local (Exim 4.50) id 1NSEP3-0001Ne-UP for user@couchdb.apache.org; Tue, 05 Jan 2010 19:45:13 +0100 Received: from e180011236.adsl.alicedsl.de ([85.180.11.236]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 05 Jan 2010 19:45:13 +0100 Received: from joscha by e180011236.adsl.alicedsl.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 05 Jan 2010 19:45:13 +0100 X-Injected-Via-Gmane: http://gmane.org/ To: user@couchdb.apache.org From: Joscha Feth Subject: Re: Modeling question Date: Tue, 05 Jan 2010 19:44:51 +0100 Lines: 45 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: e180011236.adsl.alicedsl.de User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.1.5) Gecko/20091204 Thunderbird/3.0 In-Reply-To: Sender: news X-Virus-Checked: Checked by ClamAV on apache.org Hi Chris, On 05.01.10 19:32, Chris Anderson wrote: > If you store the full path (A, B) on the Cs as well, then you can collate like: > > A, > A, B > A, B, C > A, B2 > A, B2, C > A, B2, C2 > > etc. > > If you are paginating through large directories, then you'll want to > store the parent metadata in client state, so you don't have to reload > it for each page. I don't see how that can help when a user requests a C without knowing that it is a C and has a parent B and A. I still need to either allow access or deny it. I don't see how something like this is possible with CouchDB out of the box, as I don't have the ability to make another request. > Without knowing more about the actual requirements, I can't argue this > point, but I've seen my share of cases that were simplified greatly by > moving to a key-value model. For instance, S3 has a per-bucket > security model, which is very similar to CouchDB's planned > per-database read control model. > > If you use a database-per-user (or group), quota calculations will > become much easier (and more realistic, as they account for actual > disk space used, not just total stored file size). You also get a > bunch of other simplifications (like the ability to replicate data > independently, also you don't have to worry so much about fine-grained > access control.) CouchDB can handle millions of databases on a single > node. I can not use a database per user or group, as both are completely dynamic (e.g. a user may gain or loose access on some documents any time). But I could use a separate database for any A (and storing all B's and C's within it) - would that help? I can't see how currently... regards, Joscha