com.atlassian.crowd.directory.loader
Class DbCachingRemoteDirectoryInstanceLoaderImpl
java.lang.Object
com.atlassian.crowd.directory.loader.CachingDirectoryInstanceLoader
com.atlassian.crowd.directory.loader.DbCachingRemoteDirectoryInstanceLoaderImpl
- All Implemented Interfaces:
- DirectoryInstanceLoader, InternalHybridDirectoryInstanceLoader
public class DbCachingRemoteDirectoryInstanceLoaderImpl
- extends CachingDirectoryInstanceLoader
- implements InternalHybridDirectoryInstanceLoader
Loader that allows for proxying of a remote directory through a local cache/mirror. To enable proxying for a remote
directory you should not expose its loader directly to the Crowd service, but instead delegate through this loader.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DbCachingRemoteDirectoryInstanceLoaderImpl
public DbCachingRemoteDirectoryInstanceLoaderImpl(DirectoryInstanceLoader remoteDirectoryInstanceLoader,
InternalDirectoryInstanceLoader internalDirectoryInstanceLoader,
DirectoryMonitorManager directoryMonitorManager,
DirectoryCacheFactory directoryCacheFactory,
com.atlassian.event.api.EventPublisher eventPublisher)
- Spring-friendly constructor.
- Parameters:
remoteDirectoryInstanceLoader - the remote directory instance loader.internalDirectoryInstanceLoader - the internal directory in which to do the cachingdirectoryMonitorManager - system directory monitor managereventPublisher - system event publisher
DbCachingRemoteDirectoryInstanceLoaderImpl
public DbCachingRemoteDirectoryInstanceLoaderImpl(LDAPDirectoryInstanceLoader ldapDirectoryInstanceLoader,
RemoteCrowdDirectoryInstanceLoader remoteCrowdDirectoryInstanceLoader,
InternalDirectoryInstanceLoader internalDirectoryInstanceLoader,
DirectoryMonitorManager directoryMonitorManager,
DirectoryCacheFactory directoryCacheFactory,
com.atlassian.event.api.EventPublisher eventPublisher)
- Pico-friendly constructor. Because Pico can not accept list arguments in its constructor it instead hard-codes
the two delegate loaders that JIRA needs. This constructor must have more arguments than the spring-friendly
constructor for Pico to find it.
- Parameters:
ldapDirectoryInstanceLoader - the delegate LDAP directory loaderremoteCrowdDirectoryInstanceLoader - the delegate remote Crowd directory loaderinternalDirectoryInstanceLoader - the internal directory in which to do the cachingdirectoryMonitorManager - system directory monitor managereventPublisher - system event publisher
getNewDirectory
protected RemoteDirectory getNewDirectory(Directory directory)
throws DirectoryInstantiationException
-
- Specified by:
getNewDirectory in class CachingDirectoryInstanceLoader
- Throws:
DirectoryInstantiationException
getRawDirectory
public RemoteDirectory getRawDirectory(java.lang.Long id,
java.lang.String className,
java.util.Map<java.lang.String,java.lang.String> attributes)
throws DirectoryInstantiationException
- This method will NOT wire up the internal backed directory.
So no local groups or custom attributes.
- Specified by:
getRawDirectory in interface DirectoryInstanceLoader
- Parameters:
id - Directory IDclassName - class name of directory.attributes - the configuration attributes to pass to the RemoteDirectory
- Returns:
- directory without monitoring/caching and without backing internal directory.
- Throws:
DirectoryInstantiationException
canLoad
public boolean canLoad(java.lang.String className)
- Specified by:
canLoad in interface DirectoryInstanceLoader
Copyright © 2012 Atlassian. All Rights Reserved.