我们正试图利用侦探把日志发送到zipkin。我们使用spring '2.2.6.RELEASE‘和云版本Hoxton.RELEASE。
implementation "org.springframework.cloud:spring-cloud-starter-zipkin:2.2.6.RELEASE"
implementation "org.springframework.cloud:spring-cloud-starter-sleuth:2.2.6.RELEASE"
implementation "org.springframework.cloud:spring-cloud-sleuth-zipkin:2.2.6.RELEASE"并在logback.xml %X{traceId} %X{spanId} %X{X}中添加下面的道具
由于我们的2项服务发生了上述变化,我们原以为zipkin会有一些日志,但什么也没有出现。因此,我们尝试在application.properties中添加以下属性
spring.zipkin.base-url=http://localhost:9411
spring.zipkin.enabled=true
spring.zipkin.service.name=xyz-service
spring.sleuth.enabled=true
spring.sleuth.integration.enabled=true
spring.sleuth.sampler.rate=100
spring.sleuth.sampler.probability=1.0
spring.zipkin.sender.type=web在zipkin中仍然看不到日志/服务名称。你能看到我做错了什么吗。Out应用程序也有云流依赖关系。还注意到,在日志中,我得到的X导出是假的。ex:3e205e41db60212f 77a405a53d62c9fa false
发布于 2021-10-08 10:22:26
请将项目升级到Spring和Spring的最新版本。还可以使用BOM作为版本的来源--不要手动设置它们。请不要将默认属性手动设置为默认设置。
https://stackoverflow.com/questions/69477010
复制相似问题