Hello,
I am new to Vaadin framework.
I have created a very simple Vaadin application which displays a notification message whenever a button is clicked.
public class VaadintestApplication extends Application {
@Override
public void init() {
Window mainWindow = new Window("Vaadintest Application");
setMainWindow(mainWindow);
Label label = new Label("Name");
mainWindow.addComponent(label);
final TextField nameTxtField = new TextField();
mainWindow.addComponent(nameTxtField);
getMainWindow().addComponent(new Button("Notify", new Button.ClickListener() {
private static final long serialVersionUID = 1L;
@Override
public void buttonClick(ClickEvent event) {
getMainWindow().showNotification("Notified " + nameTxtField);
}
}));
}
}
If I access the application using a single browser window, everything works perfectly fine.
I get “Out of sync” error when I follow following steps:
1) Open a browser window and access the application → the application gets loaded
2) Open another browser window and access the application → the application gets loaded
3) Now go to the “first” browser window and click on “Notify” button it displays “Out of sync” error message.
I have not performed any action but I get this error message.
What can be the reason for this message? Is this how all Vaadin applications work?
Thanks