I’m trying to use Vaadin 8.5.1 under OSGi (in karaf 4.1.2 using the OPS4J whiteboard extender).
I get the error message “Failed to load the widgetset ./…/…/widgetsets/com.vaadin.DefaultWidgetSet/com.vaadin.DefaultWidgetSet.nocache.js”
When I try accessing the URL
http://localhost:8181/fildele/./../../VAADIN/widgetsets/com.vaadin.DefaultWidgetSet/com.vaadin.DefaultWidgetSet.nocache.js?1508273514453
it is changed to
http://localhost:8181/VAADIN/widgetsets/com.vaadin.DefaultWidgetSet/com.vaadin.DefaultWidgetSet.nocache.js?1508273514453
which returns a 404.
The karaf.log has lots of messages like these:
2017-10-17T21:56:53,203 | INFO | qtp834938474-150 | VaadinServlet | 55 - com.vaadin.server - 8.1.5 | Requested resource
[/VAADIN/widgetsets/com.vaadin.DefaultWidgetSet/com.vaadin.DefaultWidgetSet.nocache.js] not found from filesystem or through class loader. Add widgetset and/or theme JAR to your classpath or add files to WebContent/VAADIN folder.
Looking at the mvn:com.vaadin/vaadin-themes/8.1.5 jar file in the local maven repository, it is an OSGi bundle that contains resources with similar paths to the missing path, but not any files containing DefaultWidgetSet in their names.
Also, the MANIFEST.MF of the OSGi bundle does not export the resources:
Export-Package: com.vaadin.osgi.themes;version=“8.1.5”
(which means the resources wouldn’t have been on the OSGi classloader’s classpath even if the path had matched a resource…)
How is this expected to work?
Thanks!