Return-Path: Delivered-To: apmail-jackrabbit-users-archive@locus.apache.org Received: (qmail 56356 invoked from network); 7 Jul 2007 11:07:54 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 7 Jul 2007 11:07:54 -0000 Received: (qmail 33010 invoked by uid 500); 7 Jul 2007 11:07:56 -0000 Delivered-To: apmail-jackrabbit-users-archive@jackrabbit.apache.org Received: (qmail 32647 invoked by uid 500); 7 Jul 2007 11:07:55 -0000 Mailing-List: contact users-help@jackrabbit.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@jackrabbit.apache.org Delivered-To: mailing list users@jackrabbit.apache.org Received: (qmail 32638 invoked by uid 99); 7 Jul 2007 11:07:55 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 07 Jul 2007 04:07:55 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: domain of david.nuescheler@gmail.com designates 64.233.166.176 as permitted sender) Received: from [64.233.166.176] (HELO py-out-1112.google.com) (64.233.166.176) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 07 Jul 2007 04:07:52 -0700 Received: by py-out-1112.google.com with SMTP id d32so1040789pye for ; Sat, 07 Jul 2007 04:07:31 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=JkqXp4O+5PEkgaaDmCDRTiERHDfrQ0Bh0wFM22pzNnZN2qavRGdK7kvneY8P5SBaEy41rzgmnZZdKt9NkajaYDVgpcrz5RgNZA/IziOLn8EhCgr7v1P2mlnIBnOjmTHOMEhMWcRBQJfphu+x1S1HVfM0e4hj3VCC8MrVCg5EMKo= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=sHbiOY/km7ZmWs1M/cGMO4dDDDxyEjMTJ/nCtrlQ9U310sdicJXxWWMHmlW857MrieXVrK0UM6Vz4dobshaWrXlPgJpy1zcLv+Ai8Wd3GLKqeOmoIMuZAZHkmXXhJGeXLOqq+1jfYde7ca+XPVJXJk5KO4Bn+jLQfcqniRQUtlU= Received: by 10.114.199.1 with SMTP id w1mr1450311waf.1183806450527; Sat, 07 Jul 2007 04:07:30 -0700 (PDT) Received: by 10.115.49.7 with HTTP; Sat, 7 Jul 2007 04:07:30 -0700 (PDT) Message-ID: Date: Sat, 7 Jul 2007 13:07:30 +0200 From: "David Nuescheler" To: users@jackrabbit.apache.org Subject: DM Rule #2: Drive the content hierarchy, don't let it happen. MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Virus-Checked: Checked by ClamAV on apache.org Explanation --- The content hierarchy is a very valuable asset. So don't just let it happen, design it. If you don't have a "good", human-readable name for a node, that's probably that you should reconsider. Arbitrary numbers are hardly ever a "good name". While it may be extremely easy to quickly put an existing relational model into a hierarchical model, one should put some thought in that process. In my experience if one thinks of access control and containment usually good drivers for the content hierarchy. Think of it as if it was your filesystem. Maybe even use files and folders to model it on your local disk. Personally I prefer hierarchy conventions over the nodetyping system in a lot of cases initially, and introduce the typing later. Example: --- I would model a simple blogging system as follows. Please note that initially I don't even care about the respective nodetypes that I use at this point. /content/myblog /content/myblog/posts /content/myblog/posts/what_i_learned_today /content/myblog/posts/iphone_shipping /content/myblog/comments/iphone_shipping/i_like_it_too /content/myblog/comments/iphone_shipping/i_like_it_too/i_hate_it I think one of the things that become apparent is that we all understand the structure of the content based on the above example without any further explanations. What may be unexpected initially is why I wouldn't store the "comments" with the "post", which is due to access control which I would like to be applied in a reasonably hierarchical way. Using the above content model I can easily allow the "anonymous" user to "create" comments, but keep the anonymous user on a read-only basis for the rest of the workspace.