Spring Cloud Sleuth provides Spring Boot auto-configuration for distributed tracing.
https://spring.io/projects/spring-cloud-sleuth#overviewZipkin is a distributed tracing system.
https://zipkin.io
Dependencies
<dependency>
<artifactId>spring-cloud-starter-sleuth</artifactId>
<groupId>org.springframework.cloud</groupId>
</dependency>
<dependency>
<artifactId>spring-cloud-sleuth-zipkin</artifactId>
<groupId>org.springframework.cloud</groupId>
</dependency>
<dependency>
<artifactId>spring-rabbit</artifactId>
<groupId>org.springframework.amqp</groupId>
</dependency>
Properties
spring.sleuth.sampler.probability=1.0
Now, if you have zipkin and rabbitmq running, you can call your service and see the traces in zipkin.
For more information see https://www.appsdeveloperblog.com/spring-cloud-sleuth-and-zipkin/
Top comments (0)