HI,
we have some problems starting a Vaadin application with @Push in Eclipse with an embedded Jetty.
The application startup in Eclipse is fine, but as soon as we start a browser session we immediately receive a
“Session expired”
it
does not work with Vaadin 8.0.3 or 8.0.4 and Jetty 9.4.x - no matter if we use the compatibility packages or the “core” Vaadin 8 packages
it
does work with Vaadin 8.0.2 (or earlier versions) and Jetty 9.4.x
and it
does work with Vaadin 8.0.3 or 8.0.4 and Jetty 9.3.x
(and of course it does work in a Tomcat environment)
@Theme(“my_valo”) @SuppressWarnings(“serial”) @PreserveOnRefresh @Push(
value = PushMode.AUTOMATIC,
transport = Transport.WEBSOCKET)
// transport = Transport.WEBSOCKET_XHR)
public class MyUI extends UI
…
We tested WEBSOCKET and WEBSOCKET_XHR without any luck using Jetty 9.4.x + Vaadin 8.0.3/8.0.4 + @PUSH
any comments from Vaadin concerning this problem ?
since the problem occurs when switching from Vaadin 7.x/Vaadin 8.0.2 to Vaadin 8.0.3/Vaadin 8.0.4 perhaps it has something to do with the changes in these releases …
we are still faced with this problem
I run the same problem enabling @Push with jetty 9.4.3 atmosphere-runtime-2.4.5.vaadin2.jar and vaadin 8.0.5
Substituting atmosphere-runtime-2.4.5.vaadin2.jar with atmosphere-runtime-2.2.7.vaadin1.jar eliminates the session expired message and shows the UI correctly, BUT there are incompatibility problems and push will not work:
java.lang.NoClassDefFoundError: org/atmosphere/cpr/AtmosphereRequestImpl
Is this only a jetty issue? Can Vaadin revert back to the earlier atmosphere and resolve the compatibility isses?
Hi,
it seem’s that I have the same problem as described here.
I switched to latest Vaadin-Version 8.0.5 and latest jetty-Version 9.4.4. and the session timed out. (We have activated PUSH-Technology)
After switching back to jetty-Version 9.3. everything is working fine.
Will this bug be fixed in the near future ?
Best regards, Roland
But the issue still persists with Jetty 9.4.5 using Vaadin 8.0.5
Hopefully atmosphere will be adapted soon to play nice with Jetty 9.4.x
Are there any plans for Vaadin to switch back to a previous version of atmosphere which works with Jetty 9.4.x in the meantime?
Hello. Trying to migrate from 7.7.10 to 8.0.* or 8.1.*
In Maven:
<vaadin.version>8.1.0.rc2</vaadin.version>
<jetty.version>9.4.2.v20170220</jetty.version>
@Push(value = PushMode.AUTOMATIC, transport = Transport.LONG_POLLING)
public class VaadinUI extends UI …
@WebServlet(value = “/*”, asyncSupported = true) @VaadinServletConfiguration(productionMode = false, ui = ReceiveOrderVaadinUI.class)
public static class Servlet extends VaadinServlet …
PUSH doesn’t work.
In logs:
java.lang.NoClassDefFoundError: org/eclipse/jetty/websocket/WebSocketFactory$Acceptor
at org.atmosphere.container.JettyServlet30AsyncSupportWithWebSocket.(JettyServlet30AsyncSupportWithWebSocket.java:46)
@Push
public final class MyUI extends UI
{
…
private void startJetty()
{
final WebAppContext webAppContext = new WebAppContext(“.”, “/”);
webAppContext.setWar(WEBROOT_DIR);
webAppContext.setClassLoader(VaadinLab.class.getClassLoader());
webAppContext.setThrowUnavailableOnStartupException(true);
webAppContext.setDescriptor(WEB_APP_CONTEXT_DESCRIPTOR_FILE);
public class MyServlet extends VaadinServlet
{
final VaadinServletService vaadinServletService = getService();
boolean isPushAvailable = vaadinServletService.ensurePushAvailable();
I receive this in logs:
окт 04, 2017 2:59:58 PM com.vaadin.server.communication.PushHandler connectionLost
SEVERE: Could not get resource. This should never happen.
окт 04, 2017 2:59:58 PM org.atmosphere.cpr.DefaultBroadcaster addAtmosphereResource
WARNING: Duplicate resource ee879653-784d-4e6f-982e-52a2cf16aefd. Could be caused by a dead connection not detected by your server. Replacing the old one with the fresh one
UI().access(new Runnable() {
@Override
public void run() {
// Some logic with making changes in UI component, updates Label, for example
UI().push();
}
});
If i comment access() method body, then it works fine, but if it is active - errors occured:
окт 05, 2017 12:22:52 PM com.vaadin.server.communication.PushHandler connectionLost
SEVERE: Could not get resource. This should never happen.
окт 05, 2017 12:22:52 PM org.atmosphere.cpr.DefaultBroadcaster addAtmosphereResource
WARNING: Duplicate resource 261820c3-1aa3-4c56-92d1-8c4f9697c94b. Could be caused by a dead connection not detected by your server. Replacing the old one with the fresh one
What i doing wrong?
In Vaadin 7.. there was no problems.