The user object is loaded on login time by spring security. Then, during the session:
How can db changes be reflected on that object?Code:User self = (User) SecurityContextHolder.getContext().getAuthentication().getPrincipal(); doSomething(self.someProperty); // not up-to-date!
Something like JPA's EntityManager.refresh() would be helpful.


Reply With Quote