Widgetset does not contain implementation

Hi,

I have a custom widget, extending com.google.gwt.user.client.ui.Composite.
This is the package structure:
src/main/java/
package.gui.widgetset.DesignsurfaceWidgetset.gwt.xml
package.gui.widgetset.client.ui.Canvas.java
package.icfd.gui.cavas.CanvasWidget

When I build with maven, via a simple “clean install” goal, on my local machine I see that this widget is added to the widgetset:
[INFO]
Widget set will contain implementations for following components:
[INFO]
bytes.connect.icfd.gui.cavas.CanvasWidget
[INFO]
com.vaadin.incubator.dragdroplayouts.DDAbsoluteLayout

However, when I do the same thing in our continuous integration (CI) environment, Jenkins or Hudson, this custom widget is never added to the set:
[INFO]
Widget set will contain implementations for following components:
[INFO]
com.vaadin.incubator.dragdroplayouts.DDAbsoluteLayout

This CI build does auto discover this custom widget:
[INFO]
auto discovered modules [package.gui.widgetset.client.ui.Canvas, package.gui.widgetset.DesignsurfaceWidgetset]

So my question is, why does this work on all the developers machines, but not with the CI build?

I’m seeing a similar problem with our Jenkins server. The compile process works fine in Eclipse and from the command line but fails to find the custom widgets when building in Jenkins.

An example from the command line;

[INFO]
— vaadin-maven-plugin:1.0.2:update-widgetset (default) @ riskflo-engage-web —
[INFO]
auto discovered modules [com.riskflo.engage.vaadin.EngageWidgetset]

[INFO]
Updating widgetset com.riskflo.engage.vaadin.EngageWidgetset
[ERROR]
Apr 17, 2013 2:50:22 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getAvailableWidgetSets
[ERROR]
INFO: Widgetsets found from classpath:
[ERROR]
com.vaadin.terminal.gwt.DefaultWidgetSet in jar:file:/Users/david/.m2/repository/com/vaadin/vaadin/6.8.7/vaadin-6.8.7.jar!/
[ERROR]
org.vaadin.hene.flexibleoptiongroup.widgetset.FlexibleOptionGroupWidgetset in jar:file:/Users/david/.m2/repository/org/vaadin/addons/flexibleoptiongroup/1.1.0/flexibleoptiongroup-1.1.0.jar!/
[ERROR]
com.riskflo.engage.vaadin.EngageWidgetset in file:/Users/david/git/debug/riskflo-engage-master/riskflo-engage-web/src/main/resources
[ERROR]
org.vaadin.csvalidation.widgetset.CSValidationWidgetset in jar:file:/Users/david/.m2/repository/org/vaadin/addons/csvalidation/0.4.1/csvalidation-0.4.1.jar!/
[ERROR]
org.vaadin.cssinject.Cssinject_addonWidgetset in jar:file:/Users/david/.m2/repository/org/vaadin/addons/cssinject/1.0/cssinject-1.0.jar!/
[ERROR]

[ERROR]
Apr 17, 2013 2:50:22 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getAvailableWidgetSets
[ERROR]
INFO: Search took 8ms

[INFO]
— gwt-maven-plugin:2.2.0:compile (default) @ riskflo-engage-web —
[INFO]
auto discovered modules [com.riskflo.engage.vaadin.EngageWidgetset]

[INFO]
Compiling module com.riskflo.engage.vaadin.EngageWidgetset
[INFO]
Scanning for additional dependencies: jar:file:/Users/david/.m2/repository/com/vaadin/vaadin/6.8.7/vaadin-6.8.7.jar!/com/vaadin/terminal/gwt/client/WidgetSet.java
[INFO]
Computing all possible rebind results for ‘com.vaadin.terminal.gwt.client.WidgetMap’
[INFO]
Rebinding com.vaadin.terminal.gwt.client.WidgetMap
[INFO]
Invoking generator com.vaadin.terminal.gwt.widgetsetutils.EagerWidgetMapGenerator
[INFO]
Detecting Vaadin components in classpath to generate WidgetMapImpl.java …
[ERROR]
Apr 17, 2013 2:50:35 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getPaintablesHavingWidgetAnnotation
[ERROR]
INFO: Searching for paintables…
[ERROR]
Apr 17, 2013 2:50:36 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getPaintablesHavingWidgetAnnotation
[ERROR]
INFO: Search took 796ms
[INFO]
Widget set will contain implementations for following components:
[INFO]
com.riskflo.engage.vaadin.CountdownClock
[INFO]
com.riskflo.engage.vaadin.ProgressIndicator
[INFO]
com.riskflo.engage.vaadin.SimpleButton
[INFO]
com.riskflo.engage.vaadin.SingleDivPanel
[INFO]
com.riskflo.engage.vaadin.UpdateStatusIndicator
[INFO]
com.vaadin.ui.AbsoluteLayout
[INFO]
com.vaadin.ui.Accordion
[INFO]
com.vaadin.ui.Audio
[INFO]
com.vaadin.ui.Button

And the equivalent from the Jenkins output;

[INFO]
— vaadin-maven-plugin:1.0.2:update-widgetset (default) @ riskflo-engage-web —
[INFO]
auto discovered modules [com.riskflo.engage.vaadin.EngageWidgetset]

[INFO]
Updating widgetset com.riskflo.engage.vaadin.EngageWidgetset
[ERROR]
Apr 17, 2013 1:16:53 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getAvailableWidgetSets
[ERROR]
INFO: Widgetsets found from classpath:
[ERROR]
com.vaadin.terminal.gwt.DefaultWidgetSet in jar:file:/usr/share/tomcat7/.m2/repository/com/vaadin/vaadin/6.8.7/vaadin-6.8.7.jar!/
[ERROR]
org.vaadin.hene.flexibleoptiongroup.widgetset.FlexibleOptionGroupWidgetset in jar:file:/usr/share/tomcat7/.m2/repository/org/vaadin/addons/flexibleoptiongroup/1.1.0/flexibleoptiongroup-1.1.0.jar!/
[ERROR]
org.vaadin.csvalidation.widgetset.CSValidationWidgetset in jar:file:/usr/share/tomcat7/.m2/repository/org/vaadin/addons/csvalidation/0.4.1/csvalidation-0.4.1.jar!/
[ERROR]
org.vaadin.cssinject.Cssinject_addonWidgetset in jar:file:/usr/share/tomcat7/.m2/repository/org/vaadin/addons/cssinject/1.0/cssinject-1.0.jar!/
[ERROR]

[ERROR]
Apr 17, 2013 1:16:53 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getAvailableWidgetSets
[ERROR]
INFO: Search took 2ms

[INFO]
— gwt-maven-plugin:2.2.0:compile (default) @ riskflo-engage-web —
[INFO]
auto discovered modules [com.riskflo.engage.vaadin.EngageWidgetset]

[INFO]
Compiling module com.riskflo.engage.vaadin.EngageWidgetset
[INFO]
Scanning for additional dependencies: jar:file:/usr/share/tomcat7/.m2/repository/com/vaadin/vaadin/6.8.7/vaadin-6.8.7.jar!/com/vaadin/terminal/gwt/client/WidgetSet.java
[INFO]
Computing all possible rebind results for ‘com.vaadin.terminal.gwt.client.WidgetMap’
[INFO]
Rebinding com.vaadin.terminal.gwt.client.WidgetMap
[INFO]
Invoking generator com.vaadin.terminal.gwt.widgetsetutils.EagerWidgetMapGenerator
[INFO]
Detecting Vaadin components in classpath to generate WidgetMapImpl.java …
[ERROR]
Apr 17, 2013 1:19:01 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getPaintablesHavingWidgetAnnotation
[ERROR]
INFO: Searching for paintables…
[ERROR]
Apr 17, 2013 1:19:11 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getPaintablesHavingWidgetAnnotation
[ERROR]
INFO: Search took 9709ms
[INFO]
Widget set will contain implementations for following components:
[INFO]
com.vaadin.ui.AbsoluteLayout
[INFO]
com.vaadin.ui.Accordion
[INFO]
com.vaadin.ui.Audio
[INFO]
com.vaadin.ui.Button

Any ideas what I’m missing or have not configured correctly?

FYI, I just ran the maven build from the command line and observed the same behaviour as if run via Jenkins. Is it possible that it could be a Centos / Java OpenJDK / class loader related issue?

Builds on Mac OS X 10.8 and Windows 7 have worked fine now and in the past.

Strange and I haven’t seen this before - though I don’t think I’ve ever used OpenJDK to compile widgetsets. Can you try locally with the same JDK version that is used on the server (OpenJDK)?

The problem occurs when scanning for component/widget classes on the classpath in an early phase of widgetset compilation.

Hi Henri,

Thanks for your response. I setup the project on a CentOS VM I created a while back to locally mirror the AWS servers we’re using for testing and ran a build which successfully found the custom widgets so it looks like the problem isn’t specific to CentOS or OpenJDK.

The OpenJDK version in the VM is;

java-1.6.0-openjdk.x86_64 1:1.6.0.0-1.57.1.11.9.el6_4

and the Jenkins server is;

java-1.6.0-openjdk.x86_64 1:1.6.0.0-57.1.11.9.52.amzn1

I’m now starting to suspect that it might have something to do with the tomcat account the Jenkins server is running under. I’ll repeat the process of setting up the project for a standard user on the build server and see what results I get and report back here again once I know more.

Build log snippets included below from CentOS & OpenJDK FYI.

[INFO]
Updating widgetset com.riskflo.engage.vaadin.EngageWidgetset
[ERROR]
Apr 18, 2013 10:14:56 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getAvailableWidgetSets
[ERROR]
INFO: Widgetsets found from classpath:
[ERROR]
com.vaadin.terminal.gwt.DefaultWidgetSet in jar:file:/home/david/.m2/repository/com/vaadin/vaadin/6.8.7/vaadin-6.8.7.jar!/
[ERROR]
org.vaadin.hene.flexibleoptiongroup.widgetset.FlexibleOptionGroupWidgetset in jar:file:/home/david/.m2/repository/org/vaadin/addons/flexibleoptiongroup/1.1.0/flexibleoptiongroup-1.1.0.jar!/
[ERROR]
com.riskflo.engage.vaadin.EngageWidgetset in file:/home/david/git/debug/riskflo-engage-master/riskflo-engage-web/src/main/resources
[ERROR]
org.vaadin.csvalidation.widgetset.CSValidationWidgetset in jar:file:/home/david/.m2/repository/org/vaadin/addons/csvalidation/0.4.1/csvalidation-0.4.1.jar!/
[ERROR]
org.vaadin.cssinject.Cssinject_addonWidgetset in jar:file:/home/david/.m2/repository/org/vaadin/addons/cssinject/1.0/cssinject-1.0.jar!/
[ERROR]

[ERROR]
Apr 18, 2013 10:14:56 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getAvailableWidgetSets
[ERROR]
INFO: Search took 15ms

[INFO]
— gwt-maven-plugin:2.2.0:compile (default) @ riskflo-engage-web —
[INFO]
auto discovered modules [com.riskflo.engage.vaadin.EngageWidgetset]

[ERROR]
Apr 18, 2013 10:14:58 PM java.util.prefs.FileSystemPreferences$2 run
[ERROR]
INFO: Created user preferences directory.
[INFO]
Compiling module com.riskflo.engage.vaadin.EngageWidgetset
[INFO]
Scanning for additional dependencies: jar:file:/home/david/.m2/repository/com/vaadin/vaadin/6.8.7/vaadin-6.8.7.jar!/com/vaadin/terminal/gwt/client/WidgetSet.java
[INFO]
Computing all possible rebind results for ‘com.vaadin.terminal.gwt.client.WidgetMap’
[INFO]
Rebinding com.vaadin.terminal.gwt.client.WidgetMap
[INFO]
Invoking generator com.vaadin.terminal.gwt.widgetsetutils.EagerWidgetMapGenerator
[INFO]
Detecting Vaadin components in classpath to generate WidgetMapImpl.java …
[ERROR]
Apr 18, 2013 10:15:36 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getPaintablesHavingWidgetAnnotation
[ERROR]
INFO: Searching for paintables…
[ERROR]
Apr 18, 2013 10:15:39 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getPaintablesHavingWidgetAnnotation
[ERROR]
INFO: Search took 3196ms
[INFO]
Widget set will contain implementations for following components:
[INFO]
com.riskflo.engage.vaadin.CountdownClock
[INFO]
com.riskflo.engage.vaadin.ProgressIndicator
[INFO]
com.riskflo.engage.vaadin.SimpleButton
[INFO]
com.riskflo.engage.vaadin.SingleDivPanel
[INFO]
com.riskflo.engage.vaadin.UpdateStatusIndicator
[INFO]
com.vaadin.ui.AbsoluteLayout
[INFO]
com.vaadin.ui.Accordion
[INFO]
com.vaadin.ui.Audio
[INFO]
com.vaadin.ui.Button

FYI, I setup the project to build under a standard user account and it picked up the custom widgets ok and built as expected.

So it looks like its a classpath issue specifically related to the user account that was automatically created to run the tomcat server that Jenkins was installed into.

Any hints as to what to look for or try next?

Log snippet below to show that the build was working ok for the standard server user (in AWS CentOS linux vm).

[INFO]
— gwt-maven-plugin:2.2.0:compile (default) @ riskflo-engage-web —
[INFO]
auto discovered modules [com.riskflo.engage.vaadin.EngageWidgetset]

[ERROR]
22/04/2013 4:48:35 AM java.util.prefs.FileSystemPreferences$2 run
[ERROR]
INFO: Created user preferences directory.
[INFO]
Compiling module com.riskflo.engage.vaadin.EngageWidgetset
[INFO]
Scanning for additional dependencies: jar:file:/home/ec2-user/.m2/repository/com/vaadin/vaadin/6.8.7/vaadin-6.8.7.jar!/com/vaadin/terminal/gwt/client/WidgetSet.java
[INFO]
Computing all possible rebind results for ‘com.vaadin.terminal.gwt.client.WidgetMap’
[INFO]
Rebinding com.vaadin.terminal.gwt.client.WidgetMap
[INFO]
Invoking generator com.vaadin.terminal.gwt.widgetsetutils.EagerWidgetMapGenerator
[INFO]
Detecting Vaadin components in classpath to generate WidgetMapImpl.java …
[ERROR]
22/04/2013 4:50:36 AM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getPaintablesHavingWidgetAnnotation
[ERROR]
INFO: Searching for paintables…
[ERROR]
22/04/2013 4:50:47 AM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getPaintablesHavingWidgetAnnotation
[ERROR]
INFO: Search took 10854ms
[INFO]
Widget set will contain implementations for following components:
[INFO]
com.riskflo.engage.vaadin.CountdownClock
[INFO]
com.riskflo.engage.vaadin.ProgressIndicator
[INFO]
com.riskflo.engage.vaadin.SimpleButton
[INFO]
com.riskflo.engage.vaadin.SingleDivPanel
[INFO]
com.riskflo.engage.vaadin.UpdateStatusIndicator
[INFO]
com.vaadin.ui.AbsoluteLayout
[INFO]
com.vaadin.ui.Accordion
[INFO]
com.vaadin.ui.Audio
[INFO]
com.vaadin.ui.Button

Hi all,

I know this is an old thread, but maybe it will help someone…

I had the same problem and just find out what caused it. There is a .(dot) in the full path of the project.
In my case the path looks like the following: /home/wso2/.jenkins/jobs/job1/project1/workspace
If I remove the .(dot) from the jenkins folder name it will work like a charm.

Cheers,
Laszlo

Hello,

I’m quite new to Vaadin and jenkins and I’ve been struggeling with what I think is a similar problem as David Eckersley - for days! I am able to build my projekt localy with NetBeans but my Jenkins server gets errors and fails. Here is a log snippet from my Jenkins build(not working) and after it a snippet from my NetBeans build (that is working). I have been trying a lot of different small changes in the project pom.xml but none of them have been successful in jenkins.

Would be very grateful for any help or tips!

I can add that the

[WARNING]
 Failed to retrieve com.vaadin:vaadin-client-compiler based on project POM

doesn’t seem to affect the build outcome. In some versions of my pom.xml this warning doesn’t occur but the outcome is the same. The same warning occurs in NetBeans build and it succeeds.

Kind regards
Kristian L

Jenkins build log (not working)

[INFO]
 Theme "VAADIN/themes/mytheme" compiled
[INFO]

[INFO]
 --- maven-resources-plugin:2.4.3:resources (default-resources) @ cvpages ---
[INFO]
 Using 'UTF-8' encoding to copy filtered resources.
[INFO]
 Copying 1 resource
[INFO]

[INFO]
 --- vaadin-maven-plugin:7.1.15:resources (default) @ cvpages ---
[INFO]
 auto discovered modules [com.vaadin.cvpages.view.AppWidgetSet]

[INFO]
 1 source files from GWT module com.vaadin.cvpages.view.AppWidgetSet
[INFO]

[INFO]
 <<< vaadin-maven-plugin:7.1.15:compile (default) @ cvpages <<<
[INFO]

[INFO]
 --- vaadin-maven-plugin:7.1.15:compile (default) @ cvpages ---
[INFO]
 auto discovered modules [com.vaadin.cvpages.view.AppWidgetSet]

[WARNING]
 Failed to retrieve com.vaadin:vaadin-client-compiler based on project POM
[INFO]
 Using com.vaadin:vaadin-client-compiler version 7.1.15

[ERROR]
 May 06, 2014 9:05:01 PM java.util.prefs.FileSystemPreferences$1 run
[ERROR]
 WARNING: Couldn't create user preferences directory. User preferences are unusable.
[ERROR]
 May 06, 2014 9:05:02 PM java.util.prefs.FileSystemPreferences$1 run
[ERROR]
 WARNING: java.io.IOException: No such file or directory

[INFO]
 Compiling module com.vaadin.cvpages.view.AppWidgetSet

[ERROR]
 May 06, 2014 9:05:32 PM java.util.prefs.FileSystemPreferences checkLockFile0ErrorCode
[ERROR]
 WARNING: Could not lock User prefs.  Unix error code 2.
[ERROR]
 May 06, 2014 9:05:32 PM java.util.prefs.FileSystemPreferences syncWorld
[ERROR]
 WARNING: Couldn't flush user prefs: java.util.prefs.BackingStoreException: Couldn't get file lock.

[ERROR]
 May 06, 2014 9:06:02 PM java.util.prefs.FileSystemPreferences checkLockFile0ErrorCode
[ERROR]
 WARNING: Could not lock User prefs.  Unix error code 2.
[ERROR]
 May 06, 2014 9:06:03 PM java.util.prefs.FileSystemPreferences syncWorld
[ERROR]
 WARNING: Couldn't flush user prefs: java.util.prefs.BackingStoreException: Couldn't get file lock.

[ERROR]
 May 06, 2014 9:06:39 PM java.util.prefs.FileSystemPreferences checkLockFile0ErrorCode
[ERROR]
 WARNING: Could not lock User prefs.  Unix error code 2.
[ERROR]
 May 06, 2014 9:06:39 PM java.util.prefs.FileSystemPreferences syncWorld
[ERROR]
 WARNING: Couldn't flush user prefs: java.util.prefs.BackingStoreException: Couldn't get file lock.

[INFO]
 ------------------------------------------------------------------------
[INFO]
 BUILD FAILURE

NetBeans build log (working)

<<< vaadin-maven-plugin:7.1.15:compile (default) @ cvpages <<<

--- vaadin-maven-plugin:7.1.15:compile (default) @ cvpages ---
auto discovered modules [com.vaadin.cvpages.view.AppWidgetSet]

Failed to retrieve com.vaadin:vaadin-client-compiler based on project POM
Using com.vaadin:vaadin-client-compiler version 7.1.15
Compiling module com.vaadin.cvpages.view.AppWidgetSet
   Computing all possible rebind results for 'com.vaadin.client.metadata.ConnectorBundleLoader'
      Rebinding com.vaadin.client.metadata.ConnectorBundleLoader
         Invoking generator com.vaadin.server.widgetsetutils.ConnectorBundleLoaderFactory
            Populating eager bundle