Hi,
I have the problem, that the redirects from Spring Security are not handled by the correct UI-class. Let me explain the structure.
I have 2 UIs the regular one and the login form. Spring Security is configured to redirect all access on “/*” to “/login”, where my login form is. Everything was working fine when I used the CDIUI-Addon (I used the extra parameter on the annotation to bind the second UI to “/login”). Unfortunately I am now forced to remove the CDI-functionality, due to complications with serializing (part of clustering the application, see
https://vaadin.com/forum#!/thread/7690939
). How can I restore the old functionality? Did I do something wrong in my thought process?
I tried the following, but it’s not working:
public class AppUI extends UI
{
@WebServlet(value = "/*", asyncSupported = true)
@VaadinServletConfiguration(productionMode = false, ui = AppUI.class)
public static class Servlet extends VaadinServlet {}
...
}
public class LoginUI extends UI
{
@WebServlet(value = "/login*", asyncSupported = true)
@VaadinServletConfiguration(productionMode = false, ui = LoginUI.class)
public static class Servlet extends VaadinServlet {}
@Override
protected void init(final VaadinRequest request)
{
//Login Form with Spring Security authentication method calls
...
}
}