[ https://issues.apache.org/jira/browse/HBASE-25424?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17252447#comment-17252447 ]
Duo Zhang commented on HBASE-25424: ----------------------------------- A basic idea is 1. Introduce an interface called HBaseTraceInitializer, and when starting master/regionserve, we will use ServiceLoader to load the implemention class, if no implementation class, just do nothing. 2. Introduce a hbase-trace-config module, which contains a class that implements HBaseTraceInitializer, to initialize the opentelemtry sdk. It will depend on opentelemetry-sdk, and only hbase-assembly module can depend on it, all other modules should not depend on it. 3. In start up scripts, introduce a flag to control whether we should enable tracing, if so, we will and the hbase-trace-config jar and related tracing jars to the classpath. I think we could introduce a special directory to hold the tracing related jars, and if users wants to export the trace data to other systems like jaeger, they could put the exporter jars under this directory and our scripts will load them automatically when tracing is enabled. > Find a way to config OpenTelemetry tracing without directly depending on > opentelemetry-sdk > ------------------------------------------------------------------------------------------ > > Key: HBASE-25424 > URL: https://issues.apache.org/jira/browse/HBASE-25424 > Project: HBase > Issue Type: Sub-task > Components: dependencies, tracing > Reporter: Duo Zhang > Priority: Major > > According to the document of OpenTelemetru, for all the modules which could > be depended by downstream users, we should only depend on opentelemetry-api. > But the open telemetry propagator must be initialized programmatically, so we > need to have a module to implement the code and introduce dependency on > opentelemetry-sdk, and we need to call it before doing anything when starting > master, regionserver, and so on. -- This message was sent by Atlassian Jira (v8.3.4#803005)