Enable tracing in java application

I added code to enable tracing in my java client apllication, I do not see any tracing in application logs. Here is my code to enable tracing :

private CouchbaseEnvironment getEnvironment() {
    Tracer tracer =
            ThresholdLogTracer.create(
                    ThresholdLogReporter.builder()
                            .n1qlThreshold(1, TimeUnit.MICROSECONDS) // 1 microsecond
                            .kvThreshold(1, TimeUnit.MICROSECONDS)
                            .logInterval(1, TimeUnit.SECONDS) // log every second
                            .sampleSize(Integer.MAX_VALUE)
                            .pretty(true) // pretty print the json output in the logs
                            .build());
    return DefaultCouchbaseEnvironment.builder().kvTimeout(kvTimeout).tracer(tracer).build();
}

The ThresholdLogTracer is always on and writes to whatever logger you have configured. Do you see INFO level logs from the SDK at startup? If you don’t even see those, then you probably need to look into your logging.