- 使用 maven 和 gradle 依赖相应的工具包
<dependency>
<groupId>org.apache.skywalking</groupId>
<artifactId>apm-toolkit-opentracing</artifactId>
<version>{project.release.version}</version>
</dependency>
- 使用OpenTracing的标准API和桥接器,使用手动埋点
Tracer tracer = new org.apache.skywalking.apm.toolkit.opentracing.SkywalkingTracer();
Tracer.SpanBuilder spanBuilder = tracer.buildSpan("/yourApplication/yourService");