how disable remoteReporter in quarkus-smallrye-opentracing

643 Views Asked by At

Request description:.
I want disable jaeger client remoteReporter, I don't nee send to agent, Because istio would make it.

Tried:.
Add quarkus.jaeger.sender-factory prop in my application.properties but I not has lucky, and can't find when use this prop in source code.

env infomation:

java version: 1.8.
quarkus version: 1.13.2.Final

example project.
GitLab link

2

There are 2 best solutions below

3
On

It seems like io.jaegertracing.internal.senders.SenderResolver which determines the Sender to use is pretty broken, which is why quarkus.jaeger.sender-factory isn't being taken into account.

One way to achieve what you want is to add a service loader file, i.e. add a file named resources/META-INF/services/io.jaegertracing.spi.SenderFactory that contains this single line:

io.jaegertracing.internal.senders.NoopSenderFactory

0
On

Try to exlude jaeger-thrift in the pom, like this:

    <dependency>
        <groupId>io.quarkus</groupId>
        <artifactId>quarkus-smallrye-opentracing</artifactId>
        <exclusions>
            <exclusion>
                <groupId>io.jaegertracing</groupId>
                <artifactId>jaeger-thrift</artifactId>
            </exclusion>
        </exclusions>
    </dependency>

what i can see in the log is only one warning about "No sender factories available. Using NoopSender".

If you add the file in meta-inf/services like the previous answer, you will not get any warnings like i describe.