On 7/23/10 12:27 PM, Tony Giaccone wrote:
> 
> On Jul 23, 2010, at 12:00 PM, Justin Edelson wrote:
>>>
>>> It seems we're playing fast and lose with the differences between a nodes 
>>> name, it's "type" and it's ordinal position.
>> Not sure what you mean here. Every node needs a name. A node's name need
>> not have a relation to the node's type or ordinal position.
>>
> 
> In my mental model of a node, it has intrinsic attributes and external 
> attributes. 
> 
> 
> Price is an example of an intrinsic attribute specific to a LineItem
> 
> Type is another example of an intrinsic attribute specific to all nodes.
> 
> 
> These are both explicitly part of the node. A lineItem has certain 
> attributes, that a paragraph does not for example. A chapter for example may 
> have a title, while a paragraph usually does not. 
> 
> The ordinal number of a lineItem in a collection of LineItems, for me, is an 
> external attribute.  It describes the location of the entity in its 
> container. Re order the entities, sort them for example by price and not id, 
> and each entity in the list ends up, potentially, with a new ordinal number. 
> 
> 
> The name  of a node, to me, feels like it should be an intrinsic property and 
> that name should be independent of where it's stored in the document. 
> 
> 
> So for me, and this is in my own little twisted model, mostly based on my 
> experience  with RDBMS, which probably makes that a flawed model for using 
> with a JCR, using the ordinal number of a node as it's "name" feels so very 
> wrong.  But maybe I just have to get over myself and let go of my previously 
> good, but what seems like currently flawed model. ;-)
> 
I did not mean to suggest that you should use the ordinal as a name.
That's why I changed my suggested data model to use a truncated UUID
instead of the ordinal.

We are in complete agreement that ordinals make for bad node names. You
seem to be saying that because ordinals are bad node names, you want to
use the type as a node name and use SNS. Ordinals may make bad node
names, but type names are worse. If you need to generate a synthetic
node name and ensure that no one assigns meaning to it, use UUIDs.

Justin

> 
> Tony

Reply via email to