Install Guide for Java EE

MVC is built on top of JAX-RS. This means that Eclipse Krazo can be run on most application servers without any additional configuration. You will just need to include the MVC API JAR as well as the Eclipse Krazo module for the JAX-RS implementation shipped with your application server.

Eclipse Krazo requires at least the Java EE 8 Web-Profile or the Eclipse MicroProfile.

The MVC specification and Eclipse Krazo are under active development. Therefore, we recommend to use the latest snapshots for your experiments. This will ensure, that you are using the latest version of both the API and the implementation. Please refer to Using the latest snapshots to learn more.

Required dependencies

The dependencies you need to add to your pom.xml file depend on which application server your are using.

Glassfish/Payara

Glassfish comes with Jersey as its JAX-RS implementation. Please add the following dependencies to your application:

<dependency>
    <groupId>javax.mvc</groupId>
    <artifactId>javax.mvc-api</artifactId>
    <version>1.0-pfd</version>
</dependency>
<dependency>
    <groupId>org.eclipse.krazo</groupId>
    <artifactId>krazo-jersey</artifactId>
    <version>1.0.0-SNAPSHOT</version>
</dependency>

Wildfly and JBoss EAP

Wildfly is using RESTEasy for JAX-RS. So you need the Eclipse Krazo RESTEasy integration module:

<dependency>
    <groupId>javax.mvc</groupId>
    <artifactId>javax.mvc-api</artifactId>
    <version>1.0-pfd</version>
</dependency>
<dependency>
    <groupId>org.eclipse.krazo</groupId>
    <artifactId>krazo-resteasy</artifactId>
    <version>1.0.0-SNAPSHOT</version>
</dependency>

Thorntail

We currently have an experimental fraction for Thorntail, but you too can use the JAX-RS fraction and add the same dependencies as required for Thorntail:

<dependency>
    <groupId>io.thorntail</groupId>
    <artifactId>jaxrs</artifactId>
</dependency>
<dependency>
    <groupId>javax.mvc</groupId>
    <artifactId>javax.mvc-api</artifactId>
    <version>1.0-pfd</version>
</dependency>
<dependency>
    <groupId>org.eclipse.krazo</groupId>
    <artifactId>krazo-resteasy</artifactId>
    <version>1.0.0-SNAPSHOT</version>
</dependency>

using fraction :

<dependency>
    <groupId>io.thorntail</groupId>
    <artifactId>mvc</artifactId>
</dependency>

Apache TomEE

Apache TomEE uses CXF as the JAX-RS implementation. Unfortunately there are some known bugs in CXF which are causing trouble for Eclipse Krazo. The latest CXF release should fix these issues, but Apache TomEE currently ships with an older CXF release.

If you want to give Eclipse Krazo on Apache TomEE a try, add the following dependencies to your pom.xml:

<dependency>
    <groupId>javax.mvc</groupId>
    <artifactId>javax.mvc-api</artifactId>
    <version>1.0-pfd</version>
</dependency>
<dependency>
    <groupId>org.eclipse.krazo</groupId>
    <artifactId>krazo-core</artifactId>
    <version>1.0.0-SNAPSHOT</version>
</dependency>

If using CXF with Eclipse Krazo is causing trouble, you can also manually add RESTEasy to your application and use this instead of CXF. To do so, use the following depndencies instead.

<dependency>
    <groupId>javax.mvc</groupId>
    <artifactId>javax.mvc-api</artifactId>
    <version>1.0-pfd</version>
</dependency>
<dependency>
    <groupId>org.eclipse.krazo</groupId>
    <artifactId>krazo-resteasy</artifactId>
    <version>1.0.0-SNAPSHOT</version>
</dependency>
<dependency>
    <groupId>org.jboss.resteasy</groupId>
    <artifactId>resteasy-cdi</artifactId>
    <version>3.6.1.Final</version>
</dependency>
<dependency>
    <groupId>org.jboss.resteasy</groupId>
    <artifactId>resteasy-servlet-initializer</artifactId>
    <version>3.6.1.Final</version>
</dependency>
<dependency>
    <groupId>org.jboss.resteasy</groupId>
    <artifactId>resteasy-validator-provider-11</artifactId>
    <version>3.6.1.Final</version>
</dependency>

That’s all. Now you can start developing your first MVC 1.0 application.