directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Emmanuel Lecharny" <>
Subject [Mitosis] Distinction between leaves and branches
Date Thu, 31 May 2007 11:36:07 GMT

I was just starting to work again on MMR, and I reached a point where
we may need to implement some lock mechanism to protect us against
concurrent access.

Let's assume these locks will be set on entries, then we will have to
know which kind of entry is the entry we want to lock. We can think of
2different kinds:
- leaves : an entry without any other entry father in the tree
- "branches" :an entry which is also the starting point for a sub tree
(nothing to do with subtrees, so the space between sub an tree)

In the first case, we can safely lock the entry
In the second case, we may have to be cautious to avoid locking the
full tree just because a telephoneNumber for this entry has been
changed ...

It would then be interesting to store a kind of virtual attribute
which hold the number of descendant within each entry. If this number
is 0, then this is a leaf.

This attribute will be created when the entry is read from the
backend, as we have the number of element at a point of the tree in
the HierarchicalIndex.

Well, this is just some "under the shower" thought I wanted to share.

Emmanuel L├ęcharny

View raw message