Skip to content

andrei-bivol/katharsis-vertx

Repository files navigation

Katharsis integration for Vertx.io

Integration and example code.

Warning
Work in progress. Katharsis-Vertx API is not stable yet as we do not support all use cases. Expect change.

Using

We deploy on https://bintray.com . You find detailed descriptions on how to consume this library on the project page https://bintray.com/netdava/maven/katharsis-vertx/ . Press Set me up button.

Add the dependency
    dependencies {
        compile 'io.katharsis:katharsis-vertx:<version>'
    }
Use in your code
    Router katharsisRouter = KatharsisRestApi.createRouter(vertx, "package.to.scan", "/api");
    router.mountSubRouter("/api/projects", katharsisRouter);
    router.mountSubRouter("/api/tasks", katharsisRouter);
Advanced usage
    ParameterProviderFactory factory = new SpringParameterProviderFactory(Json.mapper, context);
    KatharsisHandlerFactory katharsisGlue = KatharsisHandlerFactory.create(Main.class.getPackage().getName(), "/api",
            Json.mapper, factory);

    Router katharsisRouter = KatharsisRestApi.createRouter(vertx, katharsisGlue);
    router.mountSubRouter("/api/projects", katharsisRouter);
    router.mountSubRouter("/api/tasks", katharsisRouter);

Building

The project uses Gradle as a build tool.

git clone git@github.com:katharsis-project/katharsis-vertx.git
 ./gradlew build

Running examples

After building and running the commands bellow visit http://localhost:8080/api/projects or http://localhost:8080/api/tasks".

Run these commands:

The simple example uses Katharsis inheritance API.

 ./gradlew :examples:simple:run

The spring example uses a simple SpringFramework integration.

 ./gradlew :examples:spring:run

Releasing

Currently we release to https://bintray.com . We use https://github.com/ajoberstar/gradle-git plugin to manage releases in git as tags.

Add bintrayUser and bintrayApiKey to your ~/.gradle/gradle.properties file and run the bellow command:

    ./gradlew release -Prelease.scope=patch -Prelease.stage=final

Contributing

Please submit pull-requests for new features and/or bugs.

About

Vertx.io integration for Katharsis

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Languages