HTHou opened a new pull request, #1478: URL: https://github.com/apache/ratis/pull/1478
## What changes were proposed in this pull request? This patch isolates OpenTelemetry-specific tracing code behind a TraceProvider facade. The default tracing path uses a no-op provider, so downstream projects can exclude OpenTelemetry jars without loading OTel classes from the default Ratis tracing path. OpenTelemetry tracing behavior is preserved when tracing is enabled and the OpenTelemetry jars are available. The patch also removes OpenTelemetry SDK and semantic convention dependencies from the main dependency path and keeps SDK testing dependencies in test scope. ## What is the link to the Apache JIRA https://issues.apache.org/jira/browse/RATIS-2553 ## How was this patch tested? - `./mvnw -pl ratis-common,ratis-server,ratis-test -am test-compile -DskipTests` - `./mvnw -pl ratis-server -am -Dtest=RaftServerImplTracingTests -DfailIfNoTests=false test` - `./mvnw -pl ratis-server -am dependency:tree -Dscope=compile -Dincludes=io.opentelemetry,io.opentelemetry.semconv -DskipTests` - Manually verified with a classpath excluding OpenTelemetry jars that `TraceUtils.setTracerWhenEnabled(true)` falls back to no-op tracing instead of failing with linkage errors. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
