GWTCompiler and widgetset compilation, ICEPush

Hi,

I’m trying to run the simple ICEPush demo but have not been successful so far. I believe that the reason why the demo is not working is because of the widgetset having to be recompiled. But there I get the error (full stack trace below) that java.lang.ClassNotFoundException: com.google.gwt.dev.GWTCompiler. Indeed, as is documented, one should:

Replace com.google.gwt.dev.GWTCompiler -> com.google.gwt.dev.Compiler in your widget set build script (Ant) or launch configuration (Eclipse)

Unfortunately, I have no idea how to do this.

Any idea?

Thanks & kind regards,

Candide

Compiling widgetset com.fluxtream.widgetset.FluxtreamWidgetset Updating GWT module description file... Oct 25, 2010 2:06:19 AM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getAvailableWidgetSets INFO: Widgetsets found from classpath: com.vaadin.terminal.gwt.DefaultWidgetSet in jar:file:/programming/workspaces/fluxtream/SpringSecurityDemo/src/main/webapp/WEB-INF/lib/vaadin-6.4.6.jar!/ org.vaadin.artur.icepush.IcepushaddonWidgetset in jar:file:/programming/workspaces/fluxtream/SpringSecurityDemo/src/main/webapp/WEB-INF/lib/icepush-0.2.0.jar!/ com.fluxtream.widgetset.FluxtreamWidgetset in file:/programming/workspaces/fluxtream/SpringSecurityDemo/src/main/java

Done.
Starting GWT compiler
java.lang.ClassNotFoundException: com.google.gwt.dev.GWTCompiler
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:169)
at com.vaadin.tools.WidgetsetCompiler$1.run(WidgetsetCompiler.java:76)
at java.lang.Thread.run(Thread.java:637)
Widgetset compilation finished
Widgetset compilation completed

You need to have the gwt-dev.jar and gwt-user.jar on your (widgetset compilation) classpath, for a GWT version that matches your Vaadin version. For the current (at least the latest 6.4.x) versions, GWT 2.0.4 should be used. It does contain the class com.google.gwt.dev.GWTCompiler (deprecated but working), which uses the same internal mechanisms as com.google.gwt.dev.Compiler - with a little different parameter syntax.

If there is still a problem after adding the correct GWT versions on the classpath, some more information would be necessary. From where do you trigger widgetset compilation - the Eclipse plugin? Which Vaadin and GWT versions are you using? How are they specified on your project (or other) classpath?

Hi Henri,

I have two Vaadin projects right now:

  1. a Vaadin-eclipse-plugin-generated one
  2. a maven Vaadin application

I have tried different options following your answer. In both projects I have tried adding gwt 2.0.5 using the GWT eclipse plugin. In didn’t work in both. The Vaadin plugin adds its own dependencies to the build path: it didn’t have any effect. I have tried adding the dependency in the maven pom.xml: that worked!

So now I am able to generate the widgetset for my maven project. Turns out it doesn’t help me much at this point as I am trying to get a basic proof-of-concept working for the icepush mechanism. The vaadin-eclipse-plugin generated app is the bare example as provided on the Vaadin site, and that still doesn’t work.

On the other hand, in the maven app, I’m still stuck with the following error:

Cause: java.lang.UnsupportedOperationException
at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:507)
at com.vaadin.event.EventRouter.fireEvent(EventRouter.java:161)
at com.vaadin.ui.AbstractComponent.fireEvent(AbstractComponent.java:1146)
at com.fluxtream.ui.AbstractView.fireEvent(AbstractView.java:50001)
at com.fluxtream.ui.LoginView.fireEvent(LoginView.java:50001)
at com.fluxtream.ui.LoginView.access$0(LoginView.java:1)
at com.fluxtream.ui.LoginView$1.buttonClick(LoginView.java:154)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:487)
at com.vaadin.event.EventRouter.fireEvent(EventRouter.java:161)
at com.vaadin.ui.AbstractComponent.fireEvent(AbstractComponent.java:1146)
at com.vaadin.ui.Button.fireClick(Button.java:366)
at com.vaadin.ui.Button.changeVariables(Button.java:188)
at com.vaadin.terminal.gwt.server.AbstractCommunicationManager.handleVariables(AbstractCommunicationManager.java:1087)
at com.vaadin.terminal.gwt.server.AbstractCommunicationManager.doHandleUidlRequest(AbstractCommunicationManager.java:587)
at com.vaadin.terminal.gwt.server.CommunicationManager.handleUidlRequest(CommunicationManager.java:265)
at com.vaadin.terminal.gwt.server.AbstractApplicationServlet.service(AbstractApplicationServlet.java:484)
at com.fluxtream.servlet.SpringApplicationServlet.service(SpringApplicationServlet.java:182)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at com.fluxtream.servlet.SpringApplicationServlet.service(SpringApplicationServlet.java:50001)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:243)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:201)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:163)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:108)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:556)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:401)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:242)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:267)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:245)
at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:260)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:637)
Caused by: java.lang.UnsupportedOperationException
at com.vaadin.ui.CustomComponent.addComponent(CustomComponent.java:207)
at com.fluxtream.ui.AbstractView.addComponent(AbstractView.java:50001)
at com.fluxtream.ui.mgmt.HomeView.addComponent(HomeView.java:50001)
at com.vaadin.ui.Panel.addComponent(Panel.java:280)
at com.vaadin.ui.Window.addComponent(Window.java:213)
at com.fluxtream.ui.mgmt.FlxMgmtApp$1.componentEvent(FlxMgmtApp.java:150)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:487)
… 38 more
com.vaadin.event.ListenerMethod$MethodException
Cause: java.lang.NullPointerException
at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:507)
at com.vaadin.event.EventRouter.fireEvent(EventRouter.java:161)
at com.vaadin.ui.AbstractComponent.fireEvent(AbstractComponent.java:1146)
at com.vaadin.ui.Button.fireClick(Button.java:366)
at com.vaadin.ui.Button.changeVariables(Button.java:188)
at com.vaadin.terminal.gwt.server.AbstractCommunicationManager.handleVariables(AbstractCommunicationManager.java:1087)
at com.vaadin.terminal.gwt.server.AbstractCommunicationManager.doHandleUidlRequest(AbstractCommunicationManager.java:587)
at com.vaadin.terminal.gwt.server.CommunicationManager.handleUidlRequest(CommunicationManager.java:265)
at com.vaadin.terminal.gwt.server.AbstractApplicationServlet.service(AbstractApplicationServlet.java:484)
at com.fluxtream.servlet.SpringApplicationServlet.service(SpringApplicationServlet.java:182)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at com.fluxtream.servlet.SpringApplicationServlet.service(SpringApplicationServlet.java:50001)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:243)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:201)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:163)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:108)
at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:556)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:401)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:242)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:267)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:245)
at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:260)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:637)
Caused by: java.lang.NullPointerException
at com.fluxtream.ui.ExceptionUtils.handleException(ExceptionUtils.java:96)
at com.fluxtream.ui.LoginView$1.buttonClick(LoginView.java:193)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:487)
… 27 more

Any idea where I should look at now?

Thanks!

Candide

The automatically added references to GWT 2.0.4 should be correct; if you have multiple copies of the GWT JARs on the classpath, that could cause problems.

In the case of the Eclipse project, where are your add-on JARs and the JARs they depend on? You could also try the latest experimental version of the Eclipse plugin, which makes a more extensive search on the classpath for some JARs - use the update site http://vaadin.com/eclipse/experimental .

Also, make sure you have the dependencies of the add-ons you are using - at least icepush-gwt is needed by the icepush add-on.

Take a look at the indicated anonymous class in your LoginView - there is a NPE originating from there. Check what can be null on that line, and why.

Hey Henri,

I’m finally getting the widgetset to compile. Now, when I try the minimal ICEPush application from my maven project, I’m getting the following error, which is already much clearer, if still very confusing:

I have verified that I indeed have “stuff” under WEB-INF/VAADIN/widgetsets/com.fluxtream.widgetset.FluxtreamWidgetset

The contents of my widgetset file is:

<module>
	<inherits name="com.vaadin.terminal.gwt.DefaultWidgetSet" />
        <inherits name="org.vaadin.artur.icepush.IcepushaddonWidgetset" />
</module>

I must still be doing something wrong. But what is it?

Regards,

Candide

Just want to add the output from the GWT compiler, which proves that the IcePush widget was indeed compiled:

Executing compiler with parameters 
[/System/Library/Frameworks/JavaVM.framework/Versions/1.5/Home/bin/java, -Djava.awt.headless=true, -Xss8M, -Xmx512M, -XX:MaxPermSize=512M, -XstartOnFirstThread, -classpath, /System/Library/Frameworks/JavaVM.framework/Versions/1.6.0/Classes/classes.jar:/programming/workspaces/fluxtream/SpringSecurityDemo/src/main/java:/programming/workspaces/fluxtream/SpringSecurityDemo/src/main/resources:/programming/workspaces/fluxtream/SpringSecurityDemo/target/flx/WEB-INF/classes:/programming/workspaces/fluxtream/SpringSecurityDemo/target/classes:/Users/candide/.m2/repository/com/google/gwt/gwt-dev/2.0.4/gwt-dev-2.0.4.jar:/Users/candide/.m2/repository/com/google/gwt/gwt-user/2.0.4/gwt-user-2.0.4.jar:/Users/candide/.m2/repository/com/vaadin/vaadin/6.4.6/vaadin-6.4.6.jar:/programming/workspaces/fluxtream/SpringSecurityDemo/src/main/webapp/WEB-INF/lib/icepush-0.2.0.jar:/programming/workspaces/fluxtream/SpringSecurityDemo/src/main/webapp/WEB-INF/lib/vaadin-6.4.6.jar:/programming/workspaces/fluxtream/SpringSecurityDemo/src/main/webapp/WEB-INF/lib/icepush-gwt.jar, com.vaadin.tools.WidgetsetCompiler, -out, src/main/webapp/VAADIN/widgetsets, -style, PRETTY, -localWorkers, 2, -logLevel, INFO, com.fluxtream.widgetset.FluxtreamWidgetset]
Updating GWT module description file...
Oct 25, 2010 8:18:32 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getAvailableWidgetSets
INFO: Widgetsets found from classpath:
	com.vaadin.terminal.gwt.DefaultWidgetSet in jar:file:/programming/workspaces/fluxtream/SpringSecurityDemo/src/main/webapp/WEB-INF/lib/vaadin-6.4.6.jar!/
	org.vaadin.artur.icepush.IcepushaddonWidgetset in jar:file:/programming/workspaces/fluxtream/SpringSecurityDemo/src/main/webapp/WEB-INF/lib/icepush-0.2.0.jar!/
	com.fluxtream.widgetset.FluxtreamWidgetset in file:/programming/workspaces/fluxtream/SpringSecurityDemo/src/main/java

Done.
Starting GWT compiler
Compiling module com.fluxtream.widgetset.FluxtreamWidgetset
   Scanning for additional dependencies: jar:file:/Users/candide/.m2/repository/com/vaadin/vaadin/6.4.6/vaadin-6.4.6.jar!/com/vaadin/terminal/gwt/client/WidgetSet.java
      Computing all possible rebind results for 'com.vaadin.terminal.gwt.client.WidgetMap'
         Rebinding com.vaadin.terminal.gwt.client.WidgetMap
            Invoking com.google.gwt.dev.javac.StandardGeneratorContext@29c6774
               Detecting Vaadin components in classpath to generate WidgetMapImpl.java ...
               Widget set will contain implementations for following components: 
               	com.vaadin.ui.AbsoluteLayout
               	com.vaadin.ui.Accordion
               	com.vaadin.ui.Button
               	com.vaadin.ui.CheckBox
               	com.vaadin.ui.ComboBox
               	com.vaadin.ui.CssLayout
               	com.vaadin.ui.CustomComponent
               	com.vaadin.ui.CustomLayout
               	com.vaadin.ui.DateField
               	com.vaadin.ui.DragAndDropWrapper
               	com.vaadin.ui.Embedded
               	com.vaadin.ui.Form
               	com.vaadin.ui.FormLayout
               	com.vaadin.ui.GridLayout
               	com.vaadin.ui.HorizontalLayout
               	com.vaadin.ui.Label
               	com.vaadin.ui.Link
               	com.vaadin.ui.ListSelect
               	com.vaadin.ui.MenuBar
               	com.vaadin.ui.NativeButton
               	com.vaadin.ui.NativeSelect
               	com.vaadin.ui.OptionGroup
               	com.vaadin.ui.OrderedLayout
               	com.vaadin.ui.Panel
               	com.vaadin.ui.PopupView
               	com.vaadin.ui.ProgressIndicator
               	com.vaadin.ui.RichTextArea
               	com.vaadin.ui.Select
               	com.vaadin.ui.Slider
               	com.vaadin.ui.SplitPanel
               	com.vaadin.ui.TabSheet
               	com.vaadin.ui.Table
               	com.vaadin.ui.TextField
               	com.vaadin.ui.Tree
               	com.vaadin.ui.TwinColSelect
               	com.vaadin.ui.Upload
               	com.vaadin.ui.UriFragmentUtility
               	com.vaadin.ui.VerticalLayout
               	com.vaadin.ui.Window
               	org.vaadin.artur.icepush.ICEPush
               Done. (0seconds)
   Scanning for additional dependencies: jar:file:/Users/candide/.m2/repository/com/vaadin/vaadin/6.4.6/vaadin-6.4.6.jar!/com/vaadin/terminal/gwt/client/ui/dd/VAcceptCriteria.java
      Computing all possible rebind results for 'com.vaadin.terminal.gwt.client.ui.dd.VAcceptCriterionFactory'
         Rebinding com.vaadin.terminal.gwt.client.ui.dd.VAcceptCriterionFactory
            Invoking com.google.gwt.dev.javac.StandardGeneratorContext@29c6774
               Detecting available criteria ...
               creating mapping for com.vaadin.event.dd.acceptcriteria.ServerSideCriterion
               creating mapping for com.vaadin.event.dd.acceptcriteria.AcceptAll
               creating mapping for com.vaadin.ui.AbstractSelect.TargetItemIs
               creating mapping for com.vaadin.event.dd.acceptcriteria.Not
               creating mapping for com.vaadin.event.dd.acceptcriteria.SourceIsTarget
               creating mapping for com.vaadin.event.dd.acceptcriteria.And
               creating mapping for com.vaadin.event.dd.acceptcriteria.SourceIs
               creating mapping for com.vaadin.ui.Table.TableDropCriterion
               creating mapping for com.vaadin.event.dd.acceptcriteria.TargetDetailIs
               creating mapping for com.vaadin.ui.AbstractSelect.AcceptItem
               creating mapping for com.vaadin.event.dd.acceptcriteria.Or
               creating mapping for com.vaadin.ui.Tree.TargetInSubtree
               creating mapping for com.vaadin.ui.Tree.TreeDropCriterion
               creating mapping for com.vaadin.event.dd.acceptcriteria.ContainsDataFlavor
               Done. (0seconds)
   Compiling 6 permutations
      Compiling permutation 0...
      Process output
         Compiling permutation 1...
      Compiling permutation 2...
         Compiling permutation 3...
      Compiling permutation 4...
         Compiling permutation 5...
   Compile of permutations succeeded
   Linking into src/main/webapp/VAADIN/widgetsets
      Link succeeded
   Compilation succeeded -- 92.189s

Tomcat’s log were reassuring as well:


5.10.2010 20:29:58 INFO  org.springframework.web.context.ContextLoader - Root WebApplicationContext: initialization completed in 9310 ms
=================================================================
Vaadin is running in DEBUG MODE.
Add productionMode=true to web.xml to disable debug features.
To show debug window, add ?debug to your application URL.
=================================================================
Oct 25, 2010 8:30:13 PM org.icepush.servlet.MainServlet <init>
INFO: 
ICEsoft Technologies Inc.
ICEpush 0.0.1 Development
Build number: xxx
Revision: ${revision}

25.10.2010 20:30:17 INFO  com.fluxtream.servlet.SpringApplicationServlet - Using applicationBean 'applicationBean'
25.10.2010 20:30:17 DEBUG com.fluxtream.servlet.SpringApplicationServlet - Vaadin application class is [class com.fluxtream.ui.mgmt.FlxMgmtApp]

Strangely, I still get the very disappointing message:

There are strange issues with the build path though, and one thing I noticed is that I had to explicitely exclude the gwt libs from the webapp/pom in order for it to launch. OTOH, the only way for the widgetset compilation is for me to include those same gwt libraries (-user and -dev) in the pom.

Any clues?

Regards,

Candide

I would guess the widgetset is correctly compiled now, but the application is not using it. Add the correct init parameter to your web.xml (or portlet.xml), e.g.

<init-param>
    <param-name>widgetset</param-name>
    <param-value>com.fluxtream.widgetset.FluxtreamWidgetset</param-value>
</init-param>

As for the Maven issues, did you start with the latest Vaadin Maven archetype? It should also have the scope for the GWT dependencies etc. correctly set up etc. so you should not need to do anything about them.

If instead you started with the Spring application example from the incubator, it is a user contributed example and might not have been updated recently by its author. The easiest would probably be to create an empty project from the vaadin-archetype-sample and then copy the appropriate sections from there, paying close attention also to the changed structure of some configuration sections. Alternatively, read
this wiki article
, but it might be easy to miss some points if only following it.

Hey Henri,

That was it (the Servlet’s init-param). Yes you are right, I started off a SpringSecurityDemo example I found somewhere. Apart from this thing with the widgetset, it’s a example of fantastic quality.

Now everything seems to be working fine. However I’m still seeing some strange things happening. What I’ve done is I have a pusher defined as an instance variable in my main app. Then in some view later on, I have put a button, with the following click handler:

public void buttonClick(ClickEvent event) {
	Random r = new Random();
	Label l = new Label(String.valueOf(r.nextLong()));
	l6.addComponent(l);
	getApplication().createPusher();
	getApplication().pusher.push();
}

and in my main app, I have a createPusher method like so:

public void createPusher() {
	if (this.pusher==null) this.pusher = new ICEPush();
	getMainWindow().addComponent(pusher);
}

It works great, and I can see labels added up to my view each time I push the button.


However
, when I click the button the first time I get a red exclamation mark painted on it with a rollover message which says:


com.vaadin.event.ListenerMethod$MethodException
Cause: java.lang.UnsupportedOperationException
	at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:507)
	at com.vaadin.event.EventRouter.fireEvent(EventRouter.java:161)
	at com.vaadin.ui.AbstractComponent.fireEvent(AbstractComponent.java:1154)
	at com.vaadin.ui.Button.fireClick(Button.java:371)
	at com.vaadin.ui.Button.changeVariables(Button.java:193)
	at com.vaadin.terminal.gwt.server.AbstractCommunicationManager.handleVariables(AbstractCommunicationManager.java:1094)
	at com.vaadin.terminal.gwt.server.AbstractCommunicationManager.doHandleUidlRequest(AbstractCommunicationManager.java:590)
	at com.vaadin.terminal.gwt.server.CommunicationManager.handleUidlRequest(CommunicationManager.java:266)
	at com.vaadin.terminal.gwt.server.AbstractApplicationServlet.service(AbstractApplicationServlet.java:476)
	at org.vaadin.artur.icepush.ICEPushServlet.service(ICEPushServlet.java:71)
	at com.fluxtream.servlet.SpringApplicationServlet.service(SpringApplicationServlet.java:182)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
	at com.fluxtream.servlet.SpringApplicationServlet.service(SpringApplicationServlet.java:50001)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:243)
	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:201)
	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:163)
	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:108)
	at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:556)
	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:401)
	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:242)
	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:267)
	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:245)
	at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:260)
	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
	at java.lang.Thread.run(Thread.java:637)
Caused by: java.lang.UnsupportedOperationException
	at com.vaadin.ui.CustomComponent.addComponent(CustomComponent.java:208)
	at com.fluxtream.ui.AbstractView.addComponent(AbstractView.java:50001)
	at com.fluxtream.ui.mgmt.HomeView.addComponent(HomeView.java:50001)
	at com.vaadin.ui.Panel.addComponent(Panel.java:277)
	at com.vaadin.ui.Window.addComponent(Window.java:268)
	at com.fluxtream.ui.mgmt.FlxMgmtApp$$M$2b959815.createPusher(FlxMgmtApp.java:108)
	at com.fluxtream.ui.mgmt.FlxMgmtApp$$M$2b959815.__jr_selector__(FlxMgmtApp.java:50001)
	at com.fluxtream.ui.mgmt.FlxMgmtApp$$A$2b959815.__jr_selector__()
	at com.fluxtream.ui.mgmt.FlxMgmtApp.__jr_selector__(FlxMgmtApp.java:50001)
	at com.fluxtream.ui.mgmt.HomeView$4$$M$2f7c33cb.buttonClick(HomeView.java:262)
	at com.fluxtream.ui.mgmt.HomeView$4$$A$2f7c33cb.buttonClick()
	at com.fluxtream.ui.mgmt.HomeView$4.buttonClick(HomeView.java)
	at sun.reflect.GeneratedMethodAccessor38.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:487)
	... 28 more

I’m still confused, although I can see it works, it still seems like I’m missing something important here…

Thanks again for the great support and product,

Regards,

Candide

Just wanted to add that sometimes I seem to have a different message:

Cause: java.lang.RuntimeException: Must be attached to an application to push
	at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:507)
	at com.vaadin.event.EventRouter.fireEvent(EventRouter.java:161)
	at com.vaadin.ui.AbstractComponent.fireEvent(AbstractComponent.java:1154)
	at com.vaadin.ui.Button.fireClick(Button.java:371)
	at com.vaadin.ui.Button.changeVariables(Button.java:193)
	at com.vaadin.terminal.gwt.server.AbstractCommunicationManager.handleVariables(AbstractCommunicationManager.java:1094)
	at com.vaadin.terminal.gwt.server.AbstractCommunicationManager.doHandleUidlRequest(AbstractCommunicationManager.java:590)
	at com.vaadin.terminal.gwt.server.CommunicationManager.handleUidlRequest(CommunicationManager.java:266)
	at com.vaadin.terminal.gwt.server.AbstractApplicationServlet.service(AbstractApplicationServlet.java:476)
	at org.vaadin.artur.icepush.ICEPushServlet.service(ICEPushServlet.java:71)
	at com.fluxtream.servlet.SpringApplicationServlet.service(SpringApplicationServlet.java:182)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
	at com.fluxtream.servlet.SpringApplicationServlet.service(SpringApplicationServlet.java:50001)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:243)
	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:201)
	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:163)
	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:108)
	at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:556)
	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:401)
	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:242)
	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:267)
	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:245)
	at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:260)
	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
	at java.lang.Thread.run(Thread.java:637)
Caused by: java.lang.RuntimeException: Must be attached to an application to push
	at org.vaadin.artur.icepush.ICEPush.push(ICEPush.java:55)
	at com.fluxtream.ui.mgmt.FlxMgmtApp$$M$26de0faf.push(FlxMgmtApp.java:111)
	at com.fluxtream.ui.mgmt.FlxMgmtApp$$M$26de0faf.__jr_selector__(FlxMgmtApp.java:50001)
	at com.fluxtream.ui.mgmt.FlxMgmtApp$$A$26de0faf.__jr_selector__(<generated>)
	at com.fluxtream.ui.mgmt.FlxMgmtApp.__jr_selector__(FlxMgmtApp.java:50001)
	at com.fluxtream.ui.mgmt.HomeView$4$$M$5a870faa.buttonClick(HomeView.java:261)
	at com.fluxtream.ui.mgmt.HomeView$4$$A$5a870faa.buttonClick(<generated>)
	at com.fluxtream.ui.mgmt.HomeView$4.buttonClick(HomeView.java)
	at sun.reflect.GeneratedMethodAccessor38.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at com.vaadin.event.ListenerMethod.receiveEvent(ListenerMethod.java:487)
	... 28 more

As I said my ICEPush instance
is indeed
attached to my Application… And everything works as expected anyway…

Looks to me like your problem is that you call CustomComponent.addComponent which you should not. Use CustomComponent.setCompositionRoot to set the contents of the CustomComponent.

http://vaadin.com/api/com/vaadin/ui/CustomComponent.html#addComponent(com.vaadin.ui.Component)

This method is not supported by CustomComponent. Use setCompositionRoot(Component) to set CustomComponents “child”.

Hi Artur,

I can’t really make sense of what you say… If you have some time, please see the attached code for my main application and custom view (just simple tests and proof-of-concepts so far).

Cheers,

Candide


package com.fluxtream.ui.mgmt;

import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.Random;

import org.jivesoftware.smack.Chat;
import org.jivesoftware.smack.ConnectionConfiguration;
import org.jivesoftware.smack.PacketListener;
import org.jivesoftware.smack.Roster;
import org.jivesoftware.smack.XMPPConnection;
import org.jivesoftware.smack.XMPPException;
import org.jivesoftware.smack.filter.PacketTypeFilter;
import org.jivesoftware.smack.packet.Message;
import org.jivesoftware.smack.packet.Packet;
import org.jivesoftware.smack.packet.Presence;

import com.fluxtream.domain.Guest;
import com.fluxtream.services.GuestService;
import com.fluxtream.services.XmppService;
import com.fluxtream.ui.AbstractView;
import com.vaadin.data.Container;
import com.vaadin.data.Item;
import com.vaadin.data.Property;
import com.vaadin.data.util.IndexedContainer;
import com.vaadin.event.ItemClickEvent;
import com.vaadin.event.ItemClickEvent.ItemClickListener;
import com.vaadin.terminal.Resource;
import com.vaadin.terminal.ThemeResource;
import com.vaadin.ui.AbsoluteLayout;
import com.vaadin.ui.Button;
import com.vaadin.ui.Button.ClickEvent;
import com.vaadin.ui.Button.ClickListener;
import com.vaadin.ui.Component;
import com.vaadin.ui.Embedded;
import com.vaadin.ui.Label;
import com.vaadin.ui.SplitPanel;
import com.vaadin.ui.TabSheet;
import com.vaadin.ui.Table;
import com.vaadin.ui.VerticalLayout;

/**
 * TODO Document me!
 * @author Candide Kemmler
 * 
 */
public class HomeView extends AbstractView {

	private static final long serialVersionUID = -8421758733452231380L;
	
	public HomeView(FlxMgmtApp application, GuestService guestService) {
		super(application);
		this.guestService = guestService;
		init();
	}
	
	public static final String USERNAME_PROPERTY = "username";
	public static final String FIRSTNAME_PROPERTY = "firstname";
	public static final String LASTNAME_PROPERTY = "lastname";
	public static final String PRESENCE_PROPERTY = "presence";
	
	
	GuestService guestService;
	Container guestDatasource;
	private Presence currentPresence;
	
	protected XMPPConnection connection;
	MessageListener messageListener;
	
	Table table;
	
	public boolean connect(String server, Integer port, Map<String, String> parameters) throws XMPPException {
		
		final ConnectionConfiguration config = new ConnectionConfiguration(server, port);
		
		connection = new XMPPConnection(config);
		connection.connect();
		messageListener = new MessageListener();
		connection.addPacketListener(messageListener, new PacketTypeFilter(Message.class));
		
		return true;
	}
	
	private class MessageListener implements PacketListener {
		@Override
		public void processPacket(Packet packet) {
			if (packet instanceof Message) {
				@SuppressWarnings("unused")
				Message message = (Message) packet;				
			}
		}
	}
	
	protected void initXmpp() throws XMPPException {
		connect(XmppService.XMPP_HOSTNAME, XmppService.XMPP_PORT, new HashMap<String,String>());
		connection.login(XmppService.ADMIN_JID, XmppService.ADMIN_PWD);
		setPresenceMode(Presence.Type.available, Presence.Mode.available);
	}
	
	public void setPresenceMode(Presence.Type pres, Presence.Mode mod){
		currentPresence = new Presence(pres);
		currentPresence.setMode(mod);
		// Send the packet
		connection.sendPacket(currentPresence);
	}
	
	public Presence getContactPresence(String user){
		Roster roster = connection.getRoster();
		return roster.getPresence(user);
	}
	
	@SuppressWarnings("serial")
	protected void init() {
		final AbsoluteLayout mainLayout = new AbsoluteLayout();
		mainLayout.setWidth("100%");
		mainLayout.setHeight("100%");
		
		table = new Table("All Users");
		
		mainLayout.addComponent(table);
		table.setSelectable(true);
        table.setMultiSelect(true);
        table.setImmediate(true); // react at once when something is selected
		
		table.setWidth("100%");
		table.setHeight("100%");
		
		List<Guest> allGuests = guestService.getAllGuests();
		guestDatasource = getGuestDatasource(allGuests);
		table.setContainerDataSource(guestDatasource );
		table.addGeneratedColumn(PRESENCE_PROPERTY, new Table.ColumnGenerator() {
            @Override
            public Component generateCell(Table source, Object itemId, Object columnId) {
            	Item item = source.getItem(itemId);
            	Property itemProperty = item.getItemProperty(PRESENCE_PROPERTY);
                Boolean online = (Boolean)itemProperty.getValue();
				return new Embedded("",new ThemeResource(online?"icons/16/online.png":"icons/16/offline.png"));
            }
		});
		
		SplitPanel splitpanel = new SplitPanel();
		splitpanel.setSizeFull();
		splitpanel.setWidth("100%");
		// Set the orientation.
		splitpanel.setOrientation(SplitPanel.ORIENTATION_HORIZONTAL);
		// Put two components in the container.
		splitpanel.setFirstComponent(table);
		splitpanel.setSplitPosition(200, SplitPanel.UNITS_PIXELS);

		TabSheet t = addTabs();

		splitpanel.setSecondComponent(t);
		
		mainLayout.addComponent(splitpanel);
		setCompositionRoot(mainLayout);
		
		try {
			initXmpp();
		} catch (XMPPException e) {
			e.printStackTrace();
		}
	}

	private TabSheet addTabs() {
		TabSheet t = new TabSheet();
        t.setHeight("100%");
        t.setWidth("100%");
        VerticalLayout l1 = new VerticalLayout();
        l1.setMargin(true);
        l1.addComponent(new Label("bla bla."));
        // Tab 2 content
        VerticalLayout l2 = new VerticalLayout();
        l2.setMargin(true);
        l2.addComponent(new Label("There are no saved notes."));
        // Tab 3 content
        VerticalLayout l3 = new VerticalLayout();
        l3.setMargin(true);
        l3.addComponent(new Label("There are currently no issues."));
        // Tab 4 content
        VerticalLayout l4 = new VerticalLayout();
        l4.setMargin(true);
        l4.addComponent(new Label("There are no comments."));
        // Tab 5 content
        VerticalLayout l5 = new VerticalLayout();
        l5.setMargin(true);
        setupDebugPanel(l5);
        
        VerticalLayout l6 = new VerticalLayout();
        l6.setMargin(true);
        setupDebugPanel(l6);
        

        t.addTab(l1, "History", null);
        t.addTab(l2, "Profile", null);
        t.addTab(l3, "Notes", null);
        t.addTab(l4, "Comments", null);
        t.addTab(l5, "Feedback", null);
        t.addTab(l6, "Debug", null);
        
		return t;
	}

	Label dbgLabel;
	
	private void setupDebugPanel(final VerticalLayout l6) {
		dbgLabel = new Label("void");
		dbgLabel.setValue("alors, ça marche?");
		l6.addComponent(dbgLabel);
		Button button = new Button("Ask subscription");
		button.addListener(new ClickListener() {

			private static final long serialVersionUID = 1L;

			@Override
			public void buttonClick(ClickEvent event) {
				Presence currentPresence = new Presence(Presence.Type.subscribe);
				currentPresence.setFrom("sirius@fluxtream.com");
				currentPresence.setTo("ckemmler@gmail.com");
				XMPPConnection conn = connection;
				conn.sendPacket(currentPresence);
			}
			
		});
		l6.addComponent(button);
		Button chatbutton = new Button("Chat");
		chatbutton.addListener(new ClickListener() {

			private static final long serialVersionUID = 1L;

			@Override
			public void buttonClick(ClickEvent event) {
				Chat chat = connection.getChatManager().createChat("ckemmler@gmail.com", null);
				try {
					chat.sendMessage("haha");
				} catch (XMPPException e) {
					// TODO Auto-generated catch block
					e.printStackTrace();
				}
			}
			
		});
		l6.addComponent(chatbutton);
		Button pushbutton = new Button("Push");
		pushbutton.addListener(new ClickListener() {

			private static final long serialVersionUID = 1L;

			@Override
			public void buttonClick(ClickEvent event) {
				List<Guest> allGuests = guestService.getAllGuests();
				guestDatasource = getGuestDatasource(allGuests);
				Container containerDataSource = table.getContainerDataSource();
				Item item = containerDataSource.getItem(containerDataSource.getItemIds().iterator().next());
				boolean online = (Boolean) item.getItemProperty(PRESENCE_PROPERTY).getValue();
				item.getItemProperty(PRESENCE_PROPERTY).setValue(!online);
				table.setContainerDataSource(containerDataSource);
				getApplication().push();
			}
			
		});
		l6.addComponent(pushbutton);
	}
	
	private Container getGuestDatasource(List<Guest> allGuests) {
		IndexedContainer c = new IndexedContainer();
		c.addContainerProperty(USERNAME_PROPERTY, String.class, null);
		c.addContainerProperty(PRESENCE_PROPERTY, Boolean.class, null);
		for (Guest guest : allGuests) {
			Item guestItem = c.addItem(guest.getId());
			guestItem.getItemProperty(USERNAME_PROPERTY).setValue(guest.getUsername());
			guestItem.getItemProperty(PRESENCE_PROPERTY).setValue(false);
		}
		return c;
	}

}

/*
 * Copyright (c) 2010 The original author(s)
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package com.fluxtream.ui.mgmt;

import java.util.Locale;

import javax.annotation.PreDestroy;
import javax.annotation.Resource;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.context.MessageSource;
import org.springframework.context.NoSuchMessageException;
import org.springframework.context.annotation.Scope;
import org.springframework.context.i18n.LocaleContextHolder;
import org.springframework.security.authentication.AuthenticationManager;
import org.springframework.security.core.Authentication;
import org.springframework.security.core.context.SecurityContextHolder;
import org.springframework.stereotype.Component;
import org.vaadin.artur.icepush.ICEPush;

import com.fluxtream.VersionInfo;
import com.fluxtream.services.GuestService;
import com.fluxtream.ui.I18nProvider;
import com.fluxtream.ui.LoginView;
import com.vaadin.Application;
import com.vaadin.service.ApplicationContext.TransactionListener;
import com.vaadin.ui.Component.Event;
import com.vaadin.ui.Window;

@Component("applicationBean")
@Scope("prototype")
public class FlxMgmtApp extends Application implements I18nProvider,
		TransactionListener {

	private static final long serialVersionUID = -1412284137848857188L;
	ICEPush pusher;

	/**
	 * Apache Commons logger for logging stuff.
	 */
	protected final Log logger = LogFactory.getLog(getClass());

	@Resource
	private MessageSource messages;
	
	@Resource
	private AuthenticationManager authenticationManager;

	@Resource
	private GuestService guestService;

	private LoginView loginView;

	private static final Locale[] SUPPORTED_LOCALES = { Locale.US,
			new Locale("fi", "FI"), new Locale("sv", "SE") };

	private static final String[] LOCALE_NAMES = { "English", "Suomi",
			"Svenska" };

	@Override
	public Locale getLocale() {
		/*
		 * Fetch the locale resolved by Spring in the application servlet
		 */
		return LocaleContextHolder.getLocale();
	}

	@Override
	public void setLocale(Locale locale) {
		LocaleContextHolder.setLocale(locale);
	}
	
	public void push() {
		if (this.pusher==null) {
			this.pusher = new ICEPush();
			getMainWindow().addComponent(pusher);
		}
		this.pusher.push();
	}

	@SuppressWarnings("serial")
	@Override
	public void init() {
		if (logger.isDebugEnabled()) {
			logger.debug("Initializing application [" + this + "]
");
		}
		// Register listener
		getContext().addTransactionListener(this);

		// Create the views
		loginView = new LoginView(this, authenticationManager);
		loginView.setSizeFull();

		setTheme("flx"); // We use a custom theme

		final Window loginWindow = new Window(getMessage("app.title",
			getVersion()), loginView);
		setMainWindow(loginWindow);

		loginView.addListener(new com.vaadin.ui.Component.Listener() {
			@Override
			public void componentEvent(Event event) {
				if (event instanceof LoginView.LoginEvent) {
					if (logger.isDebugEnabled()) {
						logger.debug("User logged on ["
								+ ((LoginView.LoginEvent) event)
									.getAuthentication() + "]");
					}
					/*
					 * A user has logged on, which means we can ditch the login
					 * view and open the main view instead. We also have to
					 * update the security context holder.
					 */
					setUser(((LoginView.LoginEvent) event).getAuthentication());
					SecurityContextHolder.getContext().setAuthentication(
						((LoginView.LoginEvent) event).getAuthentication());
					removeWindow(loginWindow);
					loginView = null;
					HomeView homeView = new HomeView(FlxMgmtApp.this,
						guestService);
					homeView.setSizeFull();
					Window mainWindow = new Window(getMessage("app.title",
						getVersion()), homeView);
					setMainWindow(mainWindow);
				}
			}
		});
	}

	@Override
	@PreDestroy
	// In case the application is destroyed by the container
	public void close() {
		if (logger.isDebugEnabled()) {
			logger.debug("Closing application [" + this + "]
");
		}
		// Clear the authentication property to log the user out
		setUser(null);
		// Also clear the security context
		SecurityContextHolder.clearContext();
		getContext().removeTransactionListener(this);
		super.close();
	}

	@Override
	protected void finalize() throws Throwable {
		if (logger.isDebugEnabled()) {
			/*
			 * This is included to make sure that closed applications get
			 * properly garbage collected.
			 */
			logger.debug("Garbage collecting application [" + this + "]
");
		}
		super.finalize();
	}

	@Override
	public void transactionEnd(Application application, Object transactionData) {
		if (logger.isDebugEnabled()) {
			logger
				.debug("Transaction ended, removing authentication data from security context");
		}
		/*
		 * The purpose of this
		 */
		SecurityContextHolder.getContext().setAuthentication(null);
	}

	@Override
	public void transactionStart(Application application, Object transactionData) {
		if (logger.isDebugEnabled()) {
			logger
				.debug("Transaction started, setting authentication data of security context to ["
						+ application.getUser() + "]");
		}
		/*
		 * The security context holder uses the thread local pattern to store
		 * its authentication credentials. As requests may be handled by
		 * different threads, we have to update the security context holder in
		 * the beginning of each transaction.
		 */
		SecurityContextHolder.getContext().setAuthentication(
			(Authentication) application.getUser());
	}

	/**
	 * Gets the currently logged in user. If this value is <code>null</code>, no
	 * user has been logged in yet.
	 * 
	 * @return an {@link Authentication} instance.
	 */
	@Override
	public Authentication getUser() {
		return (Authentication) super.getUser();
	}

	@Override
	public String getVersion() {
		return VersionInfo.getApplicationVersion();
	}

	@Override
	public String getMessage(String code, Object... args)
			throws NoSuchMessageException {
		return messages.getMessage(code, args, getLocale());
	}

	@Override
	public Locale[] getSupportedLocales() {
		return SUPPORTED_LOCALES;
	}

	@Override
	public String getLocaleDisplayName(Locale locale) {
		for (int i = 0; i < SUPPORTED_LOCALES.length; i++) {
			if (locale.equals(SUPPORTED_LOCALES[i]
)) {
				return LOCALE_NAMES[i]
;
			}
		}
		return "Unsupported Locale";
	}
}

Hi, I am using ICE-PUSH addon for a while. It was working fine for my requirement.
I always update the Vaadin release as soon as I can, so I am currently using Vaadin 7.5.9.

I am not sure where it lies, but recently, I get the push notification updated only on the mouse move.
i.e. if I update a label via ICE-Push, the updated text appears only if we move the mouse over Vaadin application.
If mouse is on another application/window, the changes doesn’t appear.

I am pretty sure It was not the case at the beginning. I started Vaadin using 7.1.x.

Once I change the configuration to use the native Vaadin Push It this phenomena was not there.

does anybody else has the same problem?