mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
ALFCOM-2977 - Dictionary fails to re-init
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@14784 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -396,9 +396,17 @@ public class NamespaceDAOImpl implements NamespaceDAO
|
||||
private NamespaceRegistry getNamespaceRegistry(String tenantDomain)
|
||||
{
|
||||
NamespaceRegistry namespaceRegistry = null;
|
||||
|
||||
// check threadlocal first - return if set
|
||||
namespaceRegistry = getNamespaceRegistryLocal(tenantDomain);
|
||||
if (namespaceRegistry != null)
|
||||
{
|
||||
return namespaceRegistry; // return local namespaceRegistry
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
// check cache first - return if set
|
||||
// check cache second - return if set
|
||||
readLock.lock();
|
||||
namespaceRegistry = namespaceRegistryCache.get(tenantDomain);
|
||||
|
||||
@@ -412,13 +420,6 @@ public class NamespaceDAOImpl implements NamespaceDAO
|
||||
readLock.unlock();
|
||||
}
|
||||
|
||||
// check threadlocal second - return if set
|
||||
namespaceRegistry = getNamespaceRegistryLocal(tenantDomain);
|
||||
if (namespaceRegistry != null)
|
||||
{
|
||||
return namespaceRegistry; // return local namespaceRegistry
|
||||
}
|
||||
|
||||
// reset caches - may have been invalidated (e.g. in a cluster)
|
||||
namespaceRegistry = reset(tenantDomain);
|
||||
|
||||
|
Reference in New Issue
Block a user