Can you elaborate a bit on “does not work always”?
Does it mean the session is not the session is not invalidated? Or that the cookie is not removed, and you still get access to the application after logout? Or that you are not redirected somewhere?
Also, if authenticationContext is from Vaadin, it delegates the logout process and potential session invalidation to Spring Security, and it should also take care of redirect to login page if needed.
Lokally when running in IntelliJ i hit the button and the page reloads. The coockie stays in the browser and i can access the app.
After 3,4,5, times hitting the button it works, then the cookies are removed and i get forwarded to the login. It looks like the dev mode has some impact on it, could this be?
It looks like the dev mode has some impact on it, could this be?
I remember an issue with redirect being cancelled by Vite websocket forcing a page reload, but could not find the ticket right now.
And I have memories the issue was fixed at some point, but I have to double-check.