Home > Back-end >  Sleuth is not working with Spring Boot 3.0.0 Version
Sleuth is not working with Spring Boot 3.0.0 Version

Time:12-01

I am using Sleuth and Zipkin for distributed tracing and facing an issue.

Issue: TraceID and SpanID is not getting printed in the microservice logs (and passed to Zipkin) with 3.0.0 version of Spring Boot.

Following are the versions I am using:

  • Spring Boot version: 3.0.0
  • Spring cloud version: 2021.0.4
  • Zipkin Server version: zipkin-server-2.23.19-exec

application.properties:

spring.application.name=sleuthpoc2
spring.zipkin.base-url=http://localhost:9411/
spring.sleuth.sampler.probability=1.0
spring.zipkin.sender.type=WEB

CodePudding user response:

As we describe it in https://github.com/spring-cloud/spring-cloud-sleuth/tree/main

Spring Cloud Sleuth’s last minor version is 3.1. You can check the 3.1.x branch for the latest commits.

The core of this project got moved to Micrometer Tracing project and the instrumentations will be moved to Micrometer and all respective projects (no longer all instrumentations will be done in a single repository.

You can check the migration guide here https://github.com/micrometer-metrics/tracing/wiki/Spring-Cloud-Sleuth-3.1-Migration-Guide on how to migrate away from Sleuth to Micrometer Tracing.

  • Related