Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Integrates Jersey JAX-RS implementation with Vert.x application framework
Shell Java Groovy
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
gradle/wrapper
lib
src/main/java/vertx
.gitignore
README.md
build.gradle
gradlew
gradlew.bat

README.md

This project provides a simple integration between Vert.x and Jersey (JAX-RS implementation).

Here is an example of how you can use it. For instance, if you want to make your REST resources in the package com.example.resources accessible from /api:

public class Demo implements VertxApp {

    public void start() {
        RouteMatcher rm = new RouteMatcher();

        try {
            rm.all(
                "/api/.*", 
                new RestHandler(new URI("http://localhost:8080/api/")), 
                "com.example.resources");
        } catch (URISyntaxException e) {
            // Exceptions are currently not handled by the project.
            e.printStackTrace();
        }        

        server = new HttpServer().requestHandler(rm).listen(8080);
    }
}
Something went wrong with that request. Please try again.