I’m attempting to embed multiple Vaadin applications in a single page as follows:
<script type="text/javascript" src="http://localhost:9000/VAADIN/vaadinBootstrap.js"></script>
<div id="orders"></div>
<div id="chat"></div>
<script>
window.vaadin.initApplication(
"orders",
{
"versionInfo": {
"vaadinVersion": "7.7.5"
},
"browserDetailsUrl": "http://localhost:8080",
"serviceUrl": "http://localhost:8080",
"vaadinDir": "http://localhost:8080/VAADIN/",
"widgetset": "com.eyewyre.AppWidgetSet",
"theme": "apptheme",
"heartbeatInterval": "300",
"debug": true,
"standalone": false,
"authErrMsg": {
"message": "Take note of any unsaved data, and <u>click here<\/u> to continue.",
"caption": "Authentication problem"
},
"comErrMsg": {
"message": "Take note of any unsaved data, and <u>click here<\/u> to continue.",
"caption": "Communication problem"
},
"sessExpMsg": {
"message": "Take note of any unsaved data, and <u>click here<\/u> to continue.",
"caption": "Session Expired"
}
}
);
window.vaadin.initApplication(
"chat",
{
"versionInfo": {
"vaadinVersion": "7.7.5"
},
"browserDetailsUrl": "http://localhost:9000",
"serviceUrl": "http://localhost:9000",
"vaadinDir": "http://localhost:9000/VAADIN/",
"widgetset": "com.eyewyre.AppWidgetSet",
"theme": "apptheme",
"heartbeatInterval": "300",
"debug": true,
"standalone": false,
"authErrMsg": {
"message": "Take note of any unsaved data, and <u>click here<\/u> to continue.",
"caption": "Authentication problem"
},
"comErrMsg": {
"message": "Take note of any unsaved data, and <u>click here<\/u> to continue.",
"caption": "Communication problem"
},
"sessExpMsg": {
"message": "Take note of any unsaved data, and <u>click here<\/u> to continue.",
"caption": "Session Expired"
}
}
);
</script>
But as soon as the page is loaded the “Session Expired” message appears.
I’ve also tried embedding them using
Has anyone successfully embedded multiple Vaadin applications in a single page wrapper?
EDIT:
I’ve found that using the @Push annotation in both apps causes it to break.
The following errors start showing up…
Fri Jan 13 14:44:40 GMT-500 2017 com.vaadin.client.communication.MessageHandler
SEVERE: Response didn’t contain a server id. Please verify that the server is up-to-date and that the response data has not been modified in transmission.
Jan 13 14:45:36 GMT-500 2017 com.vaadin.client.communication.MessageSender
SEVERE: No active request
Thanks,
Jake