-
Notifications
You must be signed in to change notification settings - Fork 888
/
database.yaml
410 lines (403 loc) · 14.9 KB
/
database.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
groups:
- id: db
prefix: db
brief: >
This document defines the attributes used to perform database client calls.
span_kind: client
attributes:
- id: system
tag: connection-level
brief: An identifier for the database management system (DBMS) product being used. See below for a list of well-known identifiers.
required: always
type:
allow_custom_values: true
members:
- id: other_sql
value: 'other_sql'
brief: 'Some other SQL database. Fallback only. See notes.'
- id: mssql
value: 'mssql'
brief: 'Microsoft SQL Server'
- id: mysql
value: 'mysql'
brief: 'MySQL'
- id: oracle
value: 'oracle'
brief: 'Oracle Database'
- id: db2
value: 'db2'
brief: 'IBM Db2'
- id: postgresql
value: 'postgresql'
brief: 'PostgreSQL'
- id: redshift
value: 'redshift'
brief: 'Amazon Redshift'
- id: hive
value: 'hive'
brief: 'Apache Hive'
- id: cloudscape
value: 'cloudscape'
brief: 'Cloudscape'
- id: hsqldb
value: 'hsqldb'
brief: 'HyperSQL DataBase'
- id: progress
value: 'progress'
brief: 'Progress Database'
- id: maxdb
value: 'maxdb'
brief: 'SAP MaxDB'
- id: hanadb
value: 'hanadb'
brief: 'SAP HANA'
- id: ingres
value: 'ingres'
brief: 'Ingres'
- id: firstsql
value: 'firstsql'
brief: 'FirstSQL'
- id: edb
value: 'edb'
brief: 'EnterpriseDB'
- id: cache
value: 'cache'
brief: 'InterSystems Caché'
- id: adabas
value: 'adabas'
brief: 'Adabas (Adaptable Database System)'
- id: firebird
value: 'firebird'
brief: 'Firebird'
- id: derby
value: 'derby'
brief: 'Apache Derby'
- id: filemaker
value: 'filemaker'
brief: 'FileMaker'
- id: informix
value: 'informix'
brief: 'Informix'
- id: instantdb
value: 'instantdb'
brief: 'InstantDB'
- id: interbase
value: 'interbase'
brief: 'InterBase'
- id: mariadb
value: 'mariadb'
brief: 'MariaDB'
- id: netezza
value: 'netezza'
brief: 'Netezza'
- id: pervasive
value: 'pervasive'
brief: 'Pervasive PSQL'
- id: pointbase
value: 'pointbase'
brief: 'PointBase'
- id: sqlite
value: 'sqlite'
brief: 'SQLite'
- id: sybase
value: 'sybase'
brief: 'Sybase'
- id: teradata
value: 'teradata'
brief: 'Teradata'
- id: vertica
value: 'vertica'
brief: 'Vertica'
- id: h2
value: 'h2'
brief: 'H2'
- id: coldfusion
value: 'coldfusion'
brief: 'ColdFusion IMQ'
- id: cassandra
value: 'cassandra'
brief: 'Apache Cassandra'
- id: hbase
value: 'hbase'
brief: 'Apache HBase'
- id: mongodb
value: 'mongodb'
brief: 'MongoDB'
- id: redis
value: 'redis'
brief: 'Redis'
- id: couchbase
value: 'couchbase'
brief: 'Couchbase'
- id: couchdb
value: 'couchdb'
brief: 'CouchDB'
- id: cosmosdb
value: 'cosmosdb'
brief: 'Microsoft Azure Cosmos DB'
- id: dynamodb
value: 'dynamodb'
brief: 'Amazon DynamoDB'
- id: neo4j
value: 'neo4j'
brief: 'Neo4j'
- id: geode
value: 'geode'
brief: 'Apache Geode'
- id: elasticsearch
value: 'elasticsearch'
brief: 'Elasticsearch'
- id: memcached
value: 'memcached'
brief: 'Memcached'
- id: cockroachdb
value: 'cockroachdb'
brief: 'CockroachDB'
- id: connection_string
tag: connection-level
type: string
brief: >
The connection string used to connect to the database.
It is recommended to remove embedded credentials.
examples: 'Server=(localdb)\v11.0;Integrated Security=true;'
- id: user
tag: connection-level
type: string
brief: >
Username for accessing the database.
examples: ['readonly_user', 'reporting_user']
- id: jdbc.driver_classname
tag: connection-level-tech-specific
type: string
brief: >
The fully-qualified class name of the [Java Database Connectivity (JDBC)](https://docs.oracle.com/javase/8/docs/technotes/guides/jdbc/) driver used to connect.
examples: ['org.postgresql.Driver', 'com.microsoft.sqlserver.jdbc.SQLServerDriver']
- id: name
tag: call-level
type: string
required:
conditional: >
Required, if applicable and no more-specific attribute is defined.
brief: >
If no [tech-specific attribute](#call-level-attributes-for-specific-technologies)
is defined, this attribute is used to report the name of the database being accessed.
For commands that switch the database, this should be set to the target database
(even if the command fails).
note: >
In some SQL databases, the database name to be used is called "schema name".
examples: [ 'customers', 'main' ]
- id: statement
tag: call-level
type: string
required:
conditional: >
Required if applicable and not explicitly disabled via instrumentation configuration.
brief: >
The database statement being executed.
note: The value may be sanitized to exclude sensitive information.
examples: ['SELECT * FROM wuser_table', 'SET mykey "WuValue"']
- id: operation
tag: call-level
type: string
required:
conditional: Required, if `db.statement` is not applicable.
brief: >
The name of the operation being executed, e.g. the [MongoDB command name](https://docs.mongodb.com/manual/reference/command/#database-operations)
such as `findAndModify`, or the SQL keyword.
note: >
When setting this to an SQL keyword, it is not recommended to
attempt any client-side parsing of `db.statement` just to get this
property, but it should be set if the operation name is provided by
the library being instrumented.
If the SQL statement has an ambiguous operation, or performs more
than one operation, this value may be omitted.
examples: ['findAndModify', 'HMSET', 'SELECT']
- ref: net.peer.name
tag: connection-level
required:
conditional: See below.
- ref: net.peer.ip
tag: connection-level
required:
conditional: See below.
- ref: net.peer.port
tag: connection-level
required:
conditional: Required if using a port other than the default port for this DBMS.
- ref: net.transport
tag: connection-level
required:
conditional: Recommended in general, required for in-process databases (`"inproc"`).
constraints:
- any_of:
- 'net.peer.name'
- 'net.peer.ip'
- id: db.mssql
prefix: db.mssql
extends: db
brief: >
Connection-level attributes for Microsoft SQL Server
attributes:
- id: instance_name
tag: connection-level-tech-specific
type: string
note: >
If setting a `db.mssql.instance_name`, `net.peer.port` is no longer
required (but still recommended if non-standard).
brief: >
The Microsoft SQL Server [instance name](https://docs.microsoft.com/en-us/sql/connect/jdbc/building-the-connection-url?view=sql-server-ver15)
connecting to. This name is used to determine the port of a named instance.
examples: 'MSSQLSERVER'
- id: db.cassandra
prefix: db.cassandra
extends: db
brief: >
Call-level attributes for Cassandra
attributes:
- id: keyspace
type: string
required: always
tag: call-level-tech-specific-cassandra
brief: >
The name of the keyspace being accessed. To be used instead of the generic `db.name` attribute.
examples: 'mykeyspace'
- id: page_size
type: int
tag: call-level-tech-specific-cassandra
brief: >
The fetch size used for paging, i.e. how many rows will be returned at once.
examples: [5000]
- id: consistency_level
tag: call-level-tech-specific-cassandra
brief: >
The consistency level of the query. Based on consistency values from [CQL](https://docs.datastax.com/en/cassandra-oss/3.0/cassandra/dml/dmlConfigConsistency.html).
type:
members:
- id: all
value: 'all'
- id: each_quorum
value: 'each_quorum'
- id: quorum
value: 'quorum'
- id: local_quorum
value: 'local_quorum'
- id: one
value: 'one'
- id: two
value: 'two'
- id: three
value: 'three'
- id: local_one
value: 'local_one'
- id: any
value: 'any'
- id: serial
value: 'serial'
- id: local_serial
value: 'local_serial'
- id: table
type: string
tag: call-level-tech-specific-cassandra
required:
conditional: Recommended if available.
brief: The name of the primary table that the operation is acting upon, including the schema name (if applicable).
note: >
This mirrors the db.sql.table attribute but references cassandra rather than sql.
It is not recommended to attempt any client-side parsing of
`db.statement` just to get this property, but it should be set if
it is provided by the library being instrumented.
If the operation is acting upon an anonymous table, or more than one table, this
value MUST NOT be set.
examples: 'mytable'
- id: idempotence
type: boolean
tag: call-level-tech-specific-cassandra
brief: >
Whether or not the query is idempotent.
- id: speculative_execution_count
type: int
tag: call-level-tech-specific-cassandra
brief: >
The number of times a query was speculatively executed. Not set or `0` if the query was not executed speculatively.
examples: [0, 2]
- id: coordinator.id
type: string
tag: call-level-tech-specific-cassandra
brief: >
The ID of the coordinating node for a query.
examples: 'be13faa2-8574-4d71-926d-27f16cf8a7af'
- id: coordinator.dc
type: string
tag: call-level-tech-specific-cassandra
brief: >
The data center of the coordinating node for a query.
examples: 'us-west-2'
- id: db.hbase
prefix: db.hbase
extends: db
brief: >
Call-level attributes for Apache HBase
attributes:
- id: namespace
type: string
required: always
tag: call-level-tech-specific
brief: >
The [HBase namespace](https://hbase.apache.org/book.html#_namespace) being accessed.
To be used instead of the generic `db.name` attribute.
examples: 'default'
- id: db.redis
prefix: db.redis
extends: db
brief: >
Call-level attributes for Redis
attributes:
- id: database_index
type: int
required:
conditional: Required, if other than the default database (`0`).
tag: call-level-tech-specific
brief: >
The index of the database being accessed as used in the [`SELECT` command](https://redis.io/commands/select), provided as an integer.
To be used instead of the generic `db.name` attribute.
examples: [0, 1, 15]
- id: db.mongodb
prefix: db.mongodb
extends: db
brief: >
Call-level attributes for MongoDB
attributes:
- id: collection
type: string
required: always
tag: call-level-tech-specific
brief: >
The collection being accessed within the database stated in `db.name`.
examples: [ 'customers', 'products' ]
- id: db.sql
prefix: 'db.sql'
extends: 'db'
brief: >
Call-level attrbiutes for SQL databases
attributes:
- id: table
tag: call-level-tech-specific
type: string
required:
conditional: Recommended if available.
brief: The name of the primary table that the operation is acting upon, including the schema name (if applicable).
note: >
It is not recommended to attempt any client-side parsing of
`db.statement` just to get this property, but it should be set if
it is provided by the library being instrumented.
If the operation is acting upon an anonymous table, or more than one table, this
value MUST NOT be set.
examples: ['public.users', 'customers']
- id: db.tech
brief: "Semantic convention group for specific technologies"
constraints:
- include: 'db.cassandra'
- include: 'db.hbase'
- include: 'db.redis'
- include: 'db.mongodb'
- include: 'db.sql'