Elastic Search Version: 7.3.1
APM Server Version: 7.3.1
APM Client Version: 1.9.0
I am running APM Client agent along with Spring Boot based microservices. APM Client is able to instrument and able to collect traces, metric errors.
As part of the distributed tracing, i also wanted to trace.id and transaction.id in micro service logs. Our spring boot micro services use SLF4j and Logback.
I am using the property elastic.apm.enable_log_correlation=true to enable logging.
https://www.elastic.co/guide/en/apm/agent/java/current/config-logging.html
Logback configuration as follows
{ "trace.id" : "%X{trace.id}", "transaction.id" : "%X{transaction.id}" }But these configuration does not print any values for trace.id and transaction.id in my logs.
Is there dependency which i need to add to my spring boot project?