18
18
package org .apache .hadoop .hbase .trace ;
19
19
20
20
import io .opentelemetry .api .common .AttributeKey ;
21
- import io .opentelemetry .semconv .SemanticAttributes ;
21
+ import io .opentelemetry .semconv .ExceptionAttributes ;
22
+ import io .opentelemetry .semconv .incubating .DbIncubatingAttributes ;
23
+ import io .opentelemetry .semconv .incubating .RpcIncubatingAttributes ;
24
+ import io .opentelemetry .semconv .incubating .NetIncubatingAttributes ;
22
25
import java .nio .ByteBuffer ;
23
26
import java .util .List ;
24
27
import org .apache .yetus .audience .InterfaceAudience ;
25
28
26
29
/**
27
30
* The constants in this class correspond with the guidance outlined by the OpenTelemetry <a href=
28
- * "https://github.com/open-telemetry/opentelemetry-specification /tree/main/specification/trace/semantic_conventions ">Semantic
31
+ * "https://github.com/open-telemetry/semantic-conventions /tree/main/docs#opentelemetry-semantic-conventions ">Semantic
29
32
* Conventions</a>.
30
33
*/
31
34
@ InterfaceAudience .Private
32
35
public final class HBaseSemanticAttributes {
33
- public static final AttributeKey <String > DB_SYSTEM = SemanticAttributes .DB_SYSTEM ;
34
- public static final String DB_SYSTEM_VALUE = SemanticAttributes . DbSystemValues .HBASE ;
36
+ public static final AttributeKey <String > DB_SYSTEM = DbIncubatingAttributes .DB_SYSTEM ;
37
+ public static final String DB_SYSTEM_VALUE = DbIncubatingAttributes . DbSystemIncubatingValues .HBASE ;
35
38
public static final AttributeKey <String > DB_CONNECTION_STRING =
36
- SemanticAttributes .DB_CONNECTION_STRING ;
37
- public static final AttributeKey <String > DB_USER = SemanticAttributes .DB_USER ;
38
- public static final AttributeKey <String > DB_NAME = SemanticAttributes .DB_NAME ;
39
- public static final AttributeKey <String > DB_OPERATION = SemanticAttributes .DB_OPERATION ;
39
+ DbIncubatingAttributes .DB_CONNECTION_STRING ;
40
+ public static final AttributeKey <String > DB_USER = DbIncubatingAttributes .DB_USER ;
41
+ public static final AttributeKey <String > DB_NAME = DbIncubatingAttributes .DB_NAME ;
42
+ public static final AttributeKey <String > DB_OPERATION = DbIncubatingAttributes .DB_OPERATION ;
40
43
public static final AttributeKey <String > TABLE_KEY = AttributeKey .stringKey ("db.hbase.table" );
41
44
/**
42
45
* For operations that themselves ship one or more operations, such as {@link Operation#BATCH} and
@@ -46,20 +49,20 @@ public final class HBaseSemanticAttributes {
46
49
AttributeKey .stringArrayKey ("db.hbase.container_operations" );
47
50
public static final AttributeKey <List <String >> REGION_NAMES_KEY =
48
51
AttributeKey .stringArrayKey ("db.hbase.regions" );
49
- public static final AttributeKey <String > RPC_SYSTEM = SemanticAttributes .RPC_SYSTEM ;
50
- public static final AttributeKey <String > RPC_SERVICE = SemanticAttributes .RPC_SERVICE ;
51
- public static final AttributeKey <String > RPC_METHOD = SemanticAttributes .RPC_METHOD ;
52
+ public static final AttributeKey <String > RPC_SYSTEM = RpcIncubatingAttributes .RPC_SYSTEM ;
53
+ public static final AttributeKey <String > RPC_SERVICE = RpcIncubatingAttributes .RPC_SERVICE ;
54
+ public static final AttributeKey <String > RPC_METHOD = RpcIncubatingAttributes .RPC_METHOD ;
52
55
public static final AttributeKey <String > SERVER_NAME_KEY =
53
56
AttributeKey .stringKey ("db.hbase.server.name" );
54
- public static final AttributeKey <String > NET_PEER_NAME = SemanticAttributes .NET_PEER_NAME ;
55
- public static final AttributeKey <Long > NET_PEER_PORT = SemanticAttributes .NET_PEER_PORT ;
57
+ public static final AttributeKey <String > NET_PEER_NAME = NetIncubatingAttributes .NET_PEER_NAME ;
58
+ public static final AttributeKey <Long > NET_PEER_PORT = NetIncubatingAttributes .NET_PEER_PORT ;
56
59
public static final AttributeKey <Boolean > ROW_LOCK_READ_LOCK_KEY =
57
60
AttributeKey .booleanKey ("db.hbase.rowlock.readlock" );
58
61
public static final AttributeKey <String > WAL_IMPL = AttributeKey .stringKey ("db.hbase.wal.impl" );
59
62
60
- public static final AttributeKey <String > EXCEPTION_TYPE = SemanticAttributes .EXCEPTION_TYPE ;
61
- public static final AttributeKey <String > EXCEPTION_MESSAGE = SemanticAttributes .EXCEPTION_MESSAGE ;
62
- public static final String EXCEPTION_EVENT_NAME = SemanticAttributes . EXCEPTION_EVENT_NAME ;
63
+ public static final AttributeKey <String > EXCEPTION_TYPE = ExceptionAttributes .EXCEPTION_TYPE ;
64
+ public static final AttributeKey <String > EXCEPTION_MESSAGE = ExceptionAttributes .EXCEPTION_MESSAGE ;
65
+ public static final String EXCEPTION_EVENT_NAME = "exception" ;
63
66
64
67
/**
65
68
* Indicates the amount of data was read into a {@link ByteBuffer} of type
0 commit comments