Class LocalCachingAuthenticator<T extends Credentials>

  • All Implemented Interfaces:
    Authenticator<T>

    public class LocalCachingAuthenticator<T extends Credentials>
    extends InitializableObject
    implements Authenticator<T>
    An authenticator that caches the result of an authentication event locally. The authentication is delegated to a pluggable component. Add the guava dependency to use this class.
    Since:
    1.8
    Author:
    Misagh Moayyed
    • Field Detail

      • logger

        protected final org.slf4j.Logger logger
    • Constructor Detail

      • LocalCachingAuthenticator

        public LocalCachingAuthenticator()
      • LocalCachingAuthenticator

        public LocalCachingAuthenticator​(Authenticator<T> delegate,
                                         int cacheSize,
                                         int timeout,
                                         TimeUnit timeUnit)
    • Method Detail

      • removeFromCache

        public void removeFromCache​(T credentials)
      • isCached

        public boolean isCached​(T credentials)
      • setDelegate

        public void setDelegate​(Authenticator<T> delegate)
      • getCacheSize

        public int getCacheSize()
      • setCacheSize

        public void setCacheSize​(int cacheSize)
      • getTimeout

        public int getTimeout()
      • setTimeout

        public void setTimeout​(int timeout)
      • getTimeUnit

        public TimeUnit getTimeUnit()
      • setTimeUnit

        public void setTimeUnit​(TimeUnit timeUnit)