Class ConfigurableDbCachingRemoteDirectoryInstanceLoader
java.lang.Object
com.atlassian.crowd.directory.loader.AbstractDirectoryInstanceLoader
com.atlassian.crowd.directory.loader.DbCachingRemoteDirectoryInstanceLoader
com.atlassian.crowd.directory.loader.ConfigurableDbCachingRemoteDirectoryInstanceLoader
- All Implemented Interfaces:
DirectoryInstanceLoader,InternalHybridDirectoryInstanceLoader
public class ConfigurableDbCachingRemoteDirectoryInstanceLoader
extends DbCachingRemoteDirectoryInstanceLoader
A subclass of
DbCachingRemoteDirectoryInstanceLoader which allows DB caching to be switched off based
on the DirectoryProperties.CACHE_ENABLED attribute. Since 3.2.0 the uncached directories returned by this
class will be extended with auditing capabilities.
Note, the caching in this class refers to the DB caching of directory data, not of in memory caches of the
RemoteDirectory instances themselves
- Since:
- 2.8
-
Field Summary
Fields inherited from class com.atlassian.crowd.directory.loader.DbCachingRemoteDirectoryInstanceLoader
auditLogGroupMapper, auditLogUserMapper, auditService -
Constructor Summary
ConstructorsConstructorDescriptionConfigurableDbCachingRemoteDirectoryInstanceLoader(DirectoryInstanceLoader remoteDirectoryInstanceLoader, InternalDirectoryInstanceLoader internalDirectoryInstanceLoader, DirectoryCacheFactory directoryCacheFactory, CacheRefresherFactory cacheRefresherFactory, AuditService auditService, AuditLogUserMapper auditLogUserMapper, AuditLogGroupMapper auditLogGroupMapper, com.atlassian.event.api.EventPublisher eventPublisher, DirectoryDao directoryDao) -
Method Summary
Modifier and TypeMethodDescriptiongetDirectory(Directory directory) Loads theRemoteDirectoryimplementation class for a specific (already saved)Directoryconfiguration.Methods inherited from class com.atlassian.crowd.directory.loader.DbCachingRemoteDirectoryInstanceLoader
canLoad, getRawDirectory
-
Constructor Details
-
ConfigurableDbCachingRemoteDirectoryInstanceLoader
public ConfigurableDbCachingRemoteDirectoryInstanceLoader(DirectoryInstanceLoader remoteDirectoryInstanceLoader, InternalDirectoryInstanceLoader internalDirectoryInstanceLoader, DirectoryCacheFactory directoryCacheFactory, CacheRefresherFactory cacheRefresherFactory, AuditService auditService, AuditLogUserMapper auditLogUserMapper, AuditLogGroupMapper auditLogGroupMapper, com.atlassian.event.api.EventPublisher eventPublisher, DirectoryDao directoryDao)
-
-
Method Details
-
getDirectory
Description copied from interface:DirectoryInstanceLoaderLoads theRemoteDirectoryimplementation class for a specific (already saved)Directoryconfiguration.Implementations of this method may choose to cache the RemoteDirectory, so this must only be called for Directories that have been successfully saved.
- Specified by:
getDirectoryin interfaceDirectoryInstanceLoader- Overrides:
getDirectoryin classDbCachingRemoteDirectoryInstanceLoader- Parameters:
directory- The directory to load theRemoteDirectoryimplementation from.- Returns:
- The
RemoteDirectoryloaded implementation. - Throws:
DirectoryInstantiationException- If theRemoteDirectoryimplementation could not be loaded.
-