6

I have problem to run latest Vaadin 7.1.1 applications. It's mostly because I cannot find documentation for that version. Maven archetype creates old style app extending Root. Root is gone, so I'm trying to extend UI, like they do in Book of Vaadin.

web.xml:

<servlet>
    <servlet-name>myservlet</servlet-name>
    <servlet-class>
        com.vaadin.server.VaadinServlet
    </servlet-class>

    <init-param>
        <param-name>UI</param-name>
        <param-value>cz.simplecoin.simplegui.MainScreen</param-value>
    </init-param>
</servlet>

and MainScreen simply:

public class MainScreen extends UI {

Project compiles (with maven) correctly. When I debug I see init method of MainScreen called correctly, but I see only blank screen (bootstrap JavavScript is there) with the alert:

Error:

Failed to load the widgetset:./VAADIN/widgetsets/com.vaadin.DefaultWidgetSet/com.vaadin.DefaultWidgetSet.nocache.js?1393503103223

I want to start with Default widgetset. I'm almost sure that it's somehow problem in maven build/dependency. I have no Idea what libraries to use: I tried both variants (commented)

pom.xml:

<dependency>
    <groupId>com.vaadin</groupId>
    <artifactId>vaadin-server</artifactId>
    <version>${vaadin.version}</version>
</dependency>
<!--
<dependency>
    <groupId>com.vaadin</groupId>
    <artifactId>vaadin-themes</artifactId>
    <version>${vaadin.version}</version>
</dependency>
<dependency>
    <groupId>com.vaadin</groupId>
    <artifactId>vaadin-client</artifactId>
    <version>${vaadin.version}</version>
</dependency>
<dependency>
    <groupId>com.vaadin</groupId>
    <artifactId>vaadin-client-compiler</artifactId>
    <version>${vaadin.version}</version>
</dependency>
<dependency>
    <groupId>com.vaadin</groupId>
    <artifactId>vaadin-theme-compiler</artifactId>
    <version>${vaadin.version}</version>
</dependency>
<dependency>
    <groupId>com.vaadin.addon</groupId>
    <artifactId>vaadin-charts</artifactId>
    <version>1.0.0</version>
</dependency>
-->

I may try to use own widgetset,to see if that solves the issue.

2 Answers 2

12

Well I got it finally up by adapting latest demo app pom.xml directly from git. Missing widgetset is in

<dependency>
    <groupId>com.vaadin</groupId>
    <artifactId>vaadin-client-compiled</artifactId>
    <version>${vaadin.version}</version>
</dependency>
2
  • 1
    +1 for this great answer that saved my day. (sad that apparently it is way too hard to vaadin people to write a decent manual... )
    – Sanyifejű
    Jul 1, 2014 at 12:56
  • Thank you so much for posting this question and answer! What I find interesting is that this artifact is not needed to compile my Java code, but it still must be in the war for Vaadin itself to work. Not obvious! Jul 17, 2014 at 20:45
1

Than I noticed that if you run tomcat as an adapter in eclipse and you deploy your project into it, then sometimes after you have build your project, the target folder is not in sync with eclipse and you have to press F5 on it. After this action the widgetset could be loaded.

Your Answer

Reminder: Answers generated by Artificial Intelligence tools are not allowed on Stack Overflow. Learn more

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.