-
Notifications
You must be signed in to change notification settings - Fork 2
Examples
flex-ui provides a web application running in an embedded Jetty server, that allows you to view and test components that the flex-ui provides.
First, build the entire flex-ui project from source, executing
mvn install
in the root directory. Then you have several options to view the application
- Run the application via maven and the Jetty plugin. To that end, execute
mvn jetty:run
in theflex-ui-examples
module after building - Import the flex-ui project into your IDE of choice, and find the
Start
class (inflex-ui-examples/src/test/java
) and execute it. It will start an embedded Jetty server
Finally, you can find the application running at http://localhost:8080
Optionally, you can also deploy the flex-ui-examples.war
that is generated via mvn install
, which you can afterwards find in flex-ui-examples/target/
into your local Tomcat, Jetty or another Java servlet container.
When running from Start
, WebAppContext
fails at startup of context with a java.io.FileNotFoundException
The Start
class has a constant WAR_PATH
that points to the relative path of the root directory of the example web application. In some cases, depending on your IDE setup, your classpath may be set outside the project root, which can cause errors in resolving the path. Your best bet is to set the absolute path to flex-ui-examples/src/main/webapp
on your file system, and set it manually via WebAppContext#setWar(String)
(find the call in the Start
class)
When running mvn jetty:run
maven fails with an error No plugin found for prefix 'jetty'
Most likely you are not running the command from within flex-ui-examples
When running mvn jetty:run
maven fails with an error Failed to execute goal on project flex-ui-examples: Could not resolve dependencies for project
Have you built the project from the root directory with mvn install
?