Invalidate cache before loadData() (2.1.1.2)
This commit is contained in:
+2
@@ -84,6 +84,7 @@ public class CachingAuthenticationService implements ICachingAuthenticationServi
|
||||
@PostConstruct
|
||||
@Override
|
||||
public void loadData() {
|
||||
clearCache();
|
||||
for (IRider rider : daoFactory.createRiderDAO().findAll()) {
|
||||
userCache.putIfAbsent(rider.getEmail(), rider.getPassword());
|
||||
}
|
||||
@@ -92,6 +93,7 @@ public class CachingAuthenticationService implements ICachingAuthenticationServi
|
||||
@Override
|
||||
public void clearCache() {
|
||||
userCache.clear();
|
||||
tokenCache.clear();
|
||||
}
|
||||
|
||||
private byte[] generateSHA1(String string) {
|
||||
|
||||
Reference in New Issue
Block a user