wildfly 23.0.1.Final 带有 jaegertracing 异常

wildfly 23.0.1.Final with jaegertracing exception

我 运行 在 Wildfly 23.0.1.Final (openjdk 11) 在 Centos 8.

我根本没有在我的应用程序中使用 opentrace,我也没有添加任何 jaeger 依赖项。 每当我查看日志时,我经常会收到如下所示的异常(级别:警告):

> 021-04-28 15:08:29,875 WARN  [io. .internal.reporters.RemoteReporter]
> (jaeger.RemoteReporter-QueueProcessor) FlushCommand execution failed!
> Repeated errors of this command will not be logged.:
> io.jaegertracing.internal.exceptions.SenderException: Failed to flush
> spans.    at
> io.jaegertracing.jaeger@1.5.0//io.jaegertracing.thrift.internal.senders.ThriftSender.flush(ThriftSender.java:115)
>   at
> io.jaegertracing.jaeger@1.5.0//io.jaegertracing.internal.reporters.RemoteReporter$FlushCommand.execute(RemoteReporter.java:160)
>   at
> io.jaegertracing.jaeger@1.5.0//io.jaegertracing.internal.reporters.RemoteReporter$QueueProcessor.run(RemoteReporter.java:182)
>   at java.base/java.lang.Thread.run(Thread.java:834) Caused by:
> io.jaegertracing.internal.exceptions.SenderException: Could not send 1
> spans     at
> io.jaegertracing.jaeger@1.5.0//io.jaegertracing.thrift.internal.senders.UdpSender.send(UdpSender.java:85)
>   at
> io.jaegertracing.jaeger@1.5.0//io.jaegertracing.thrift.internal.senders.ThriftSender.flush(ThriftSender.java:113)
>   ... 3 more Caused by:
> org.apache.thrift.transport.TTransportException: Cannot flush closed
> transport     at
> io.jaegertracing.jaeger@1.5.0//io.jaegertracing.thrift.internal.reporters.protocols.ThriftUdpTransport.flush(ThriftUdpTransport.java:148)
>   at
> org.apache.thrift@0.13.0//org.apache.thrift.TServiceClient.sendBase(TServiceClient.java:73)   at
> org.apache.thrift@0.13.0//org.apache.thrift.TServiceClient.sendBaseOneway(TServiceClient.java:66)
>   at
> io.jaegertracing.jaeger@1.5.0//io.jaegertracing.agent.thrift.Agent$Client.send_emitBatch(Agent.java:70)
>   at
> io.jaegertracing.jaeger@1.5.0//io.jaegertracing.agent.thrift.Agent$Client.emitBatch(Agent.java:63)
>   at
> io.jaegertracing.jaeger@1.5.0//io.jaegertracing.thrift.internal.senders.UdpSender.send(UdpSender.java:83)
>   ... 4 more Caused by: java.net.PortUnreachableException: ICMP Port
> Unreachable   at java.base/java.net.PlainDatagramSocketImpl.send(Native
> Method)   at
> java.base/java.net.DatagramSocket.send(DatagramSocket.java:695)   at
> io.jaegertracing.jaeger@1.5.0//io.jaegertracing.thrift.internal.reporters.protocols.ThriftUdpTransport.flush(ThriftUdpTransport.java:146)
>   ... 9 more

这些消息填满了日志文件,我不知道如何禁用不需要的 opentrace 功能。 我无法在 google 上找到关于这个奇怪异常的信息。 有人知道吗?

此致

谢恩

如果您不使用它,您可以在 CLI 中执行类似以下操作:

/subsystem=microprofile-opentracing-smallrye/jaeger-tracer=jaeger:write-attribute(name=sampler-param, value=0)

另一种解决方案是删除 opentracing 子系统,安装 jaeger 或等待 WildFly 发布并修复 https://issues.redhat.com/browse/WFLY-14625

您可以通过移除

来禁用它
<subsystem xmlns="urn:wildfly:microprofile-opentracing-smallrye:3.0" default-tracer="jaeger">
    <jaeger-tracer name="jaeger">
        <sampler-configuration sampler-type="const" sampler-param="1.0"/>
    </jaeger-tracer>
</subsystem>

在standalone.xml

与 wildfly 并行,执行 jaeger 应用程序 - 一个日志跟踪器,具有合适的端口配置。您可能会找到一张 docker 图片到 运行。