/java-with-dagger-demo

Simple demo of the dagger.io java demo

Primary LanguageJava

java-with-dagger-demo

This project contains a very simple demo of the dagger.io java SDK. It reproduces the dagger sample code visible on the dagger homepage.

build

Java SDK

The Java SDK is part of the dagger/dagger git repository.

Build the Java SDK according to the documentation

Make sure that you install it to your local maven cache.

Dagger demo

$ ./gradlew build

run

Run the demo code

$ ./gradlew run

use Dagger CLI

To run a Java pipeline the Java SDK is needed as jar file containing all dependencies.

This self-contained jar can be built with this command:

$ ./gradlew customFatJar

The following command uses the Dagger CLI to start the demo code:

$ dagger run java -cp app/build/libs/all-in-one-jar.jar org.chelonix.dagger.demo.App