1 package dst.ass2.service.auth;
3 import dst.ass2.service.api.auth.AuthenticationException;
4 import dst.ass2.service.api.auth.IAuthenticationService;
5 import dst.ass2.service.api.auth.NoSuchUserException;
7 public interface ICachingAuthenticationService extends IAuthenticationService {
13 * Instead of checking database records directly, the method first checks the cache for existing users. If the user
14 * is not in the cache, then the service checks the database for the given email address, and updates the cache if
19 String authenticate(String email, String password) throws NoSuchUserException, AuthenticationException;
22 * Loads user data from the database into memory.
27 * Clears the data cached from the database.