Continous deployment and Vaadin

EDIT this only applies when starting in development mode, so not relevant for this discussion.

I have isolated an example, which i think demonstrates the essence of what i’m trying to get at.

  • Use the vaadin helloworld starter
  • In Application.java, add this to persist sessions across restarts
  @Component
  public class CustomContainer
      implements WebServerFactoryCustomizer<TomcatServletWebServerFactory> {

    @Override
    public void customize(TomcatServletWebServerFactory factory) {
      factory.addContextCustomizers(
          context -> {
            context.setManager(new PersistentManager());
            FileStore fileStore = new FileStore();
            // can be any directory
            fileStore.setDirectory(System.getProperty("java.io.tmpdir"));
            ((PersistentManager) context.getManager()).setStore(fileStore);
          });
    }
  }
  • Start the application. On the home screen fill out the text field and press the button
  • Stop the application. Verify that a .session file is written to java.io.tmpdir. The browser screen shows no errors.
  • Start the application again. Go back to the browser, press the button. The screen will do a full page refresh. The jsessionid did not change.

From my birds eye view then, given that there were no code changes, and that the session state was fully persisted, and the session id did not change, why is there a full page refresh? Distributed session stores or kubernetes-kit have nothing to do with this.