Skip to content

derXear/opentracing-spring-boot-jaeger-example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

OpenTracing Spring Boot example with Jaeger

Build Status Coverage Status

In this example we are running 2 services:

  • hello-service
  • greetings-service

Both are using java-spring-jaeger by including the following dependency

<dependency>
    <groupId>io.opentracing.contrib</groupId>
    <artifactId>opentracing-spring-jaeger-web-starter</artifactId>
    <version>1.0.3</version>
</dependency>

Hello service will run on port 8888 and exposes the enpoint /hello. This endpoint returns the String "Hello from Service"

Greetings service will run on port 8080 and exposes the enpoint /greetings/hello. When calling this endpoint, this service calls the hello-service and returns the String received in the response.

When a request is processed, traces are sent to the Jaeger tool, where you get a detailed view of the process. You can access the Jaeger UI via the following link http://localhost:16686/

Build/run the example

Example can be run with docker-compose. Build:

docker-compose build

Run:

docker-compose up

Call endpoint: http://localhost:8080/greetings/hello

and you will see the traces by accessing to Jaeger at http://localhost:16686/

About

OpenTracing with Spring Boot for Jaeger

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published