* Dependency the toolkit, such as using maven or gradle ```xml org.apache.skywalking apm-toolkit-log4j-2.x {project.release.version} ``` * Config the `[%traceId]` pattern in your log4j2.xml ```xml ``` * When you use `-javaagent` to active the sky-walking tracer, log4j2 will output **traceId**, if it existed. If the tracer is inactive, the output will be `TID: N/A`.