Skip to content

Latest commit

 

History

History
82 lines (68 loc) · 3.14 KB

README.md

File metadata and controls

82 lines (68 loc) · 3.14 KB

helidon-conference

Example for conferences

The MP and SE project were generated using helidon quickstart and then modified to live in a single pom project (e.g. dependency management and plugin management is unified in parent project).

conference-se

mvn archetype:generate -DinteractiveMode=false \
    -DarchetypeGroupId=io.helidon.archetypes \
    -DarchetypeArtifactId=helidon-quickstart-se \
    -DarchetypeVersion=1.1.1 \
    -DgroupId=io.helidon.examples \
    -DartifactId=conference-se \
    -Dpackage=io.helidon.examples.conference.se

conference-mp

mvn archetype:generate -DinteractiveMode=false \
    -DarchetypeGroupId=io.helidon.archetypes \
    -DarchetypeArtifactId=helidon-quickstart-mp \
    -DarchetypeVersion=1.1.1 \
    -DgroupId=io.helidon.examples \
    -DartifactId=conference-mp \
    -Dpackage=io.helidon.examples.conference.mp

Startup

To start SE application, just use java -jar, or run it from IDE. To start MP application, you need to provide the following system properties to correctly decrypt password from config:

-Dsecurity.config.aes.insecure-passphrase=myVerySecureMasterPasswordForConference 
-Dsecurity.config.require-encryption=false

Endpoints

Each application opens a few endpoints that return JSON messages.

conference-se

conference-mp

Tracing

To see traces of the calls, I use Zipkin tracer. To replicate the same behavior, simply start Zipkin docker image:

First time: docker run -d -p 9411:9411 openzipkin/zipkin

If Zipkin is already installed: docker start zipkin

This command will start "Zipkin" on default host and port. If you have Zipkin running on a different location than http://localhost:9411, you need to re-configure the application:

application.yaml:

# Listing default values 
tracing:
    service: "service-name" # Existing configuration
    protocol: "http"
    host: "localhost"
    port: 9411
    api-version: "2"
    enabled: true