Loading...
Important Notice - Forums is archived

To simplify things and help our users to be more productive, we have archived the current forum and focus our efforts on helping developers on Stack Overflow. You can post new questions on Stack Overflow or join our Discord channel.

Product icon
TUTORIAL

Vaadin lets you build secure, UX-first PWAs entirely in Java.
Free ebook & tutorial.

Problem getting Vaadin Flow to work from embedded jetty and Gradle

Mike Cooper
2 years ago Apr 30, 2020 1:33am
Mike Cooper
2 years ago Apr 30, 2020 2:18am
Erik Lumme
2 years ago Apr 30, 2020 6:02am
Mike Cooper
2 years ago Apr 30, 2020 5:53pm
Mike Cooper
2 years ago Apr 30, 2020 7:00pm

I was able to get this to work from Eclipse by adding "build\classes\java\main" to the eclipse launcher classpath.

Martin Vyšný
2 years ago May 08, 2020 5:10am
Mike Cooper
2 years ago May 08, 2020 3:29pm
Stefano Bossi
2 years ago Sep 03, 2020 3:02pm
Stefano Bossi
2 years ago Sep 11, 2020 7:10am

Dear Forum,

I found a solution to this problem and I am now able to use Visual Studio Code with Vaadin, Gradle and a Jetty embedded. The short answer is that you have to add this configuration in the gradle build file:

eclipse {
    classpath {
        file {
            whenMerged {
                def src = entries.find { it.path == 'src/main/java' }
                src.output = "/$eclipse.project.name/classes/main-java"
            }
        }
    }
}

You could find more information and a complete skeleton project here: Visual Code Studio @Route error For the complete explanation the info are here: Gradle and Buidship not working for Vaadin project and here: Improved Java project synchronization

Regards, S.