mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-14 17:58:59 +00:00
ALF-12866: WebDAV in-memory locking - threading issues.
* LockInfo instances provide a ReentrantReadWriteLock for clients to use * LockInfo client code synchronises uses provided RRWLs. git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@34212 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -924,9 +924,17 @@ public class PropFindMethod extends WebDAVMethod
|
||||
// Output the lock status response
|
||||
|
||||
LockInfo lockInfo = getNodeLockInfo(nodeInfo);
|
||||
if (lockInfo.isLocked())
|
||||
lockInfo.getRWLock().readLock().lock();
|
||||
try
|
||||
{
|
||||
generateLockDiscoveryXML(xml, nodeInfo, lockInfo);
|
||||
if (lockInfo.isLocked())
|
||||
{
|
||||
generateLockDiscoveryXML(xml, nodeInfo, lockInfo);
|
||||
}
|
||||
}
|
||||
finally
|
||||
{
|
||||
lockInfo.getRWLock().readLock().unlock();
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user