Skip to content

Commit

Permalink
Document CXF removal and remove it as supported
Browse files Browse the repository at this point in the history
Signed-off-by: Erdle, Tobias <tobi.erdle@gmail.com>
  • Loading branch information
erdlet committed Apr 12, 2021
1 parent e2805a0 commit 3a9f93a
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 80 deletions.
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Thanks for your interest in this project.
## Project description

Eclipse Krazo is an implementation of action-based MVC specifiec by MVC 1.0 (JSR-371).
It builds on top of JAX-RS and currently contains support for RESTEasy, Jersey and CXF
It builds on top of JAX-RS and currently contains support for RESTEasy and Jersey
with a well-defined SPI for other implementations.

## Developer resources
Expand Down
24 changes: 1 addition & 23 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Eclipse Krazo

Eclipse Krazo is an implementation of action-based MVC specified by Jakarta MVC 2.0. It builds on top of Jakarta RESTful Webservices
and currently contains support for RESTEasy, Jersey and CXF with a well-defined SPI for other implementations.
and currently contains support for RESTEasy and Jersey with a well-defined SPI for other implementations.

## Running the testsuite

Expand All @@ -12,8 +12,6 @@ The following sections describe how you test Eclipse Krazo against them. At the

- Glassfish 8
- WildFly 22.x.x
- TomEE 10.x
- OpenLiberty 20.0.0.12

### Preconditions
- JDK 11
Expand All @@ -33,26 +31,6 @@ To run the Krazo testsuite with WildFly, you need to follow these steps:
2. Start WildFly with `sh standalone.sh --debug`. This enables you to remote-debug the Arquillian tests.
3. Go into the `testsuite` package of Eclipse Krazo and execute `mvn clean integration-test -Ptestsuite-wildfly`

### TomEE
To run the Krazo testsuite with TomEE, you need to follow these steps:
1. Download TomEE from the TomEE [download page](https://tomee.apache.org/download-ng.html) and unzip it somewhere you'll find it again.
2. Overwrite or enable the following settings in `${TOMEE_HOME}/conf/system.properties` to get Arquillian to run:
```
tomee.remote.support=true
tomee.serialization.class.blacklist=-
openejb.system.apps = true
```
3. Start TomEE with `sh catalina.sh jpda start`. This enables you to remote-debug the Arquillian tests.
4. Go into the `testsuite` package of Eclipse Krazo and execute `mvn clean integration-test -Ptestsuite-tomee`

### OpenLiberty
To run the Krazo testsuite with OpenLiberty, you need to follow these steps. Please note that this process has been tested with 20.x only.

1. Download OpenLiberty from the [official download page](https://openliberty.io/downloads/) and unzip it.
2. Replace the file `wlp/templates/servers/defaultServer/server.xml` with `.travis/wlp-server-template.xml` from the Eclipse Krazo repository.
3. Go into the `testsuite` package of Eclipse Krazo and execute `mvn clean integration-test -Ptestsuite-glassfish -Dliberty.home=c:/somewhere/wlp/`.
Please make sure to replace `c:/somewhere/wlp/` with the absolute path to the unpacked OpenLiberty distribution.

### Troubleshooting

#### Tests are failing locally but not in Jenkins
Expand Down
2 changes: 1 addition & 1 deletion documentation/src/main/asciidoc/_intro.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
== Introduction
Eclipse Krazo is an implementation of action-based MVC specified by MVC 1.0 (JSR-371).
It builds on top of JAX-RS and currently contains support for RESTEasy, Jersey and CXF
It builds on top of JAX-RS and currently contains support for RESTEasy and Jersey
with a well-defined SPI for other implementations.
This is user guide for Eclipse Krazo {krazo-version}.
Expand Down
84 changes: 29 additions & 55 deletions documentation/src/main/asciidoc/_quickstart.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -64,26 +64,9 @@ mvn archetype:generate \
....
====== TomEE / OpenLiberty (CXF)
Krazo won't support CXF anymore. As OpenLiberty is going to switch to RESTEasy until it supports Jakarta REST Web Services 3.0, this change is only relevant for TomEE in general and older versions of OpenLiberty.
[source, subs="attributes"]
....
mvn archetype:generate \
-DarchetypeGroupId=org.eclipse.krazo \
-DarchetypeArtifactId=krazo-jakartaee8-archetype \
-DarchetypeVersion={krazo-version} \
-DgroupId=YOUR GROUP ID \
-DartifactId=YOUR ARTIFACT ID \
-DkrazoImpl=cxf
....
===== Manual setup
If you can't or just don't want to use the archetype, you can set up Krazo easily by yourself. Please follow the guides below for
your server. 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:
To use Krazo on those servers anyway, you can add e.g. RESTEasy as a compile time dependency to your artifact:
[source,xml]
----
Expand All @@ -94,14 +77,31 @@ application:
</dependency>
<dependency>
<groupId>org.eclipse.krazo</groupId>
<artifactId>krazo-jersey</artifactId>
<artifactId>krazo-resteasy</artifactId>
<version>{{versions.krazo.latest}}</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>
----
====== Wildfly and JBoss EAP
Wildfly is using RESTEasy for JAX-RS. So you need the Eclipse Krazo RESTEasy integration module:
====== Glassfish/Payara
Glassfish comes with Jersey as its JAX-RS implementation. Please add the following dependencies to your
application:
[source,xml]
----
Expand All @@ -112,18 +112,14 @@ Wildfly is using RESTEasy for JAX-RS. So you need the Eclipse Krazo RESTEasy int
</dependency>
<dependency>
<groupId>org.eclipse.krazo</groupId>
<artifactId>krazo-resteasy</artifactId>
<artifactId>krazo-jersey</artifactId>
<version>{{versions.krazo.latest}}</version>
</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.
====== Wildfly and JBoss EAP
If you want to give Eclipse Krazo on Apache TomEE a try, add the following dependencies to your `pom.xml`:
Wildfly is using RESTEasy for JAX-RS. So you need the Eclipse Krazo RESTEasy integration module:
[source,xml]
----
Expand All @@ -134,13 +130,14 @@ If you want to give Eclipse Krazo on Apache TomEE a try, add the following depen
</dependency>
<dependency>
<groupId>org.eclipse.krazo</groupId>
<artifactId>krazo-core</artifactId>
<artifactId>krazo-resteasy</artifactId>
<version>{{versions.krazo.latest}}</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 dependencies instead.
====== Apache TomEE
To use Krazo on TomEE, you can add RESTEasy as a compile time dependency, as CXF isn't supported anymore by Krazo.
[source,xml]
----
Expand Down Expand Up @@ -341,29 +338,6 @@ with Eclipse Krazo, you have to consider following configurations.
You don't need additional configuration, as Krazo is auto-loaded by implementation-specific SPIs.
===== CXF
As CXF doesn't provide any SPI to enforce the initialization of Eclipse Krazo, you need to configure all necessary
providers manually in `Application#getClasses`. Please have a look into the snippet below, which shows an example
implementation of `Application#getClasses`.
....
public class MyApplication extends Application {
@Override
public Set<Class<?>> getClasses() {
final Set<Class<?>> classes = new HashSet<>();
...
// Add Krazo features
classes.addAll(org.eclipse.krazo.bootstrap.DefaultConfigProvider.PROVIDERS);
return classes;
}
}
....
=== Creating you first controller
The following steps will show you how to create your first Controller using Eclipse Krazo. It assumes, that you've set up a project like we described before.
Expand Down

0 comments on commit 3a9f93a

Please sign in to comment.