El vie, 07-09-2007 a las 17:26 +0200, Dominique Pfister escribió: > Hi Paco > > On 06/09/2007, Paco Avila <[EMAIL PROTECTED]> wrote: > > When an user locks a node, a lock token is added to his session. Another > > user with this lock token added to his session can unlock the node, > > isn't it? > > Yes, but only if the first session in your example removes the lock > token, as there can only be one session having that lock token at a > given time.
Yes, you are right. Another session had the lock token :/ > > > > But Jackrabbit test also the lock owner (LockManagerImpl.java line 345), > > but the especification says in 8.4.4 "The lock owner's ID is provided > > for informational purposes only, it is not tested..." > > In the specified source code section, the "lock holder" is tested, not > the "lock owner". The lock owner (or lock creator) is the user id of > the session, that originally locked the node and purely informational. > The lock holder is the session currently holding the lock token and is > therefore allowed to change this node (and its descendants if the lock > is deep). Sorry, I missunderstood the code because confused "lock holder" and "lock ownser" concepts :( The lock (and lockToken) behavior is ok, my code was incorrect. Sorry! :) -- Paco Avila <[EMAIL PROTECTED]>
