我正在尝试将 jaeger 跟踪集成到我的 java spring 应用程序中。我在配置文件中添加了以下代码:
@Bean public io.opentracing.Tracer jaegerTracer(){
Sender sender = new HttpSender("http://localhost:14268/api/traces");
com.uber.jaeger.Configuration.SenderConfiguration senderConfiguration = new com.uber.jaeger.Configuration
.SenderConfiguration.Builder()
.sender(sender)
.build();
return new com.uber.jaeger.Configuration("pilot-tracking",
new com.uber.jaeger.Configuration.SamplerConfiguration(ProbabilisticSampler.TYPE, 1),
new com.uber.jaeger.Configuration.ReporterConfiguration(sender)).getTracer();
}
并使用以下 docker 命令:
docker run -d -p 5775:5775/udp -p 6831:6831/udp -p 6832:6832/udp -p 5778:5778 -p 16686:16686 -p 14268:14268 jaegertracing/一体机:最新
尽管如此,我还是无法在 jaeger-ui 中找到我的服务
点击此网址后: http://localhost:5778/?service=pilot-tracking 输出为:tcollector 错误:tchannel 错误 ErrCodeBadRequest:服务“jaeger-collector”和方法“SamplingManager::getSamplingStrategy”没有处理程序
请帮忙!!