Sunday, November 21, 2010

Vaadin TouchKit and Google App Engine = Session expired / Out of sync errors?

I've been developing with Vaadin, Vaadin TouchKit (for Mobile UI), and Google App Engine... and getting a lot of these messages:

Out of sync Something has caused us to be out of sync with the server.
Take note of any unsaved data, and click here to re-sync.

Also session expired messages......

Any ideas / solutions / workarounds ?

I'm considering switching to JSF 2.0 + PrimeFaces ...

6 comments:

  1. Not a real solution, but a "dirty" workaround. How about not showing the ugry red message at all, but to just set the application to reload the page? In most cases the user doesn't even notice anything funny happening (just an additional page reload). In order to do this, see Application.CustomizedSystemMessages

    ReplyDelete
  2. A real solution would be to solve the actual problem. In most cases you are getting the error for returning the same window instance for more than one web browser. In order to resolve this out, search forums for "multible tabs".

    Also otherwise asking on the forums might help.

    ReplyDelete
  3. Yeah, get on the Vaadin forum. Hard to guess what the cause is with this little info...

    ReplyDelete
  4. Thank you friends.

    I think I only experience it on Google App Engine... My last experience with Vaadin+GlassFish seems flawless.

    ReplyDelete
  5. i know it's late but I hope this will be useful to somebody:
    i was experiencing the same problem too..
    mark absolutely all classes as serializable!
    extend the appropriate servlet in web.xml before deploying to app engine.

    ReplyDelete
  6. For GAE apps you should extend GAEServlet and for Touchkit apps, you should extend TouchkitApplicationServlet, so you need to make your own servlet type which extends GAEApplicationServlet and adds the needed tk app servlet overridden methods. The problem I noticed is that touchkit is not fully serializable. I think at least in TouchKitWindow there's a set of application icons that are not serializable.

    ReplyDelete