On Thu, May 5, 2011 at 7:02 PM, [email protected] <[email protected]> wrote: > > Stefan Guggisberg wrote: >> >> yes. references are stored on the target. for every mix:referenceable node >> currently being referenced by 1-n reference properties there's one record >> in the REFS table. that record stores the collection of property id's >> refering to the corresponding mix:referenceable node. >> > > So if I use weak references, would there be a seperate record for the > reference? in REFS or any other table?
no. > I understand that referential integrity will not be enforced in that case. correct. > > > Stefan Guggisberg wrote: >> >> both forward and reverse lookups are highly efficient. >> > > Can you explain how forward lookup is done when there is no pointer to > referenced node in referencing node data? Only way I can think of is to > triverse all rows in REFS table along with their blob untill you find > referencing node id in the blob. i can't follow you here. forward lookup => referenceProperty.getNode() the internal value of a refererence property *is* the unique identifier of the target node, i.e. the target node is *directly* accessed using its unique identifier. > > > Stefan Guggisberg wrote: >> >> the drawback of this approach is limited scalability. 10k and more >> references to any particular node slow down write performance, i.e. adding >> an additional reference to a target node already being referenced by lets >> say 100k properties is relatively slow since the the entire collection of >> referer id's needs to be stored. >> > > I suppose this will not be an issue with weak references, assuming there is > no record of reference in REFS or any other table. Am I right? yes. cheers stefan > > Thanks, > KS > > -- > View this message in context: > http://jackrabbit.510166.n4.nabble.com/Jackrabbit-Reference-Lookup-tp3494206p3498886.html > Sent from the Jackrabbit - Users mailing list archive at Nabble.com. >
