Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge DB connection-level and call-level attributes #780

Merged
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .chloggen/780.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
change_type: enhancement
component: db
note: Merge DB connection-level and call-level attributes tables
issues: [780]
4 changes: 2 additions & 2 deletions docs/database/cassandra.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ described on this page.

`db.system` MUST be set to `"cassandra"`.

## Call-level attributes
## Attributes

<!-- semconv db.cassandra(full,tag=call-level-tech-specific-cassandra) -->
<!-- semconv db.cassandra(full,tag=tech-specific) -->
| Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---|
| [`db.cassandra.consistency_level`](../attributes-registry/db.md) | string | 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). | `all` | Recommended |
Expand Down
4 changes: 2 additions & 2 deletions docs/database/cosmosdb.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@ extend and override the [Database Semantic Conventions](database-spans.md)
that describe common database operations attributes in addition to the Semantic Conventions
described on this page.

## Call-level attributes
## Attributes

`db.system` MUST be set to `"cosmosdb"`.

Cosmos DB instrumentation includes call-level (public API) surface spans and network spans. Depending on the connection mode (Gateway or Direct), network-level spans may also be created.

<!-- semconv db.cosmosdb(full,tag=call-level-tech-specific) -->
<!-- semconv db.cosmosdb(full,tag=tech-specific) -->
| Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---|
| [`db.cosmosdb.client_id`](../attributes-registry/db.md) | string | Unique Cosmos client instance id. | `3ba4827d-4422-483f-b59f-85b74211c11d` | Recommended |
Expand Down
4 changes: 2 additions & 2 deletions docs/database/couchdb.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ described on this page.

`db.system` MUST be set to `"couchdb"`.

## Call-level attributes
## Attributes

<!-- semconv db.couchdb(full,tag=call-level-tech-specific) -->
<!-- semconv db.couchdb(full,tag=tech-specific) -->
| Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---|
| [`db.operation`](../attributes-registry/db.md) | string | The HTTP method + the target REST route. [1] | `GET /{db}/{docid}` | Conditionally Required: If `db.statement` is not applicable. |
Expand Down
18 changes: 9 additions & 9 deletions docs/database/database-metrics.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ This metric is [required][MetricRequired].
<!-- semconv metric.db.client.connections.usage(full) -->
| Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---|
| `pool.name` | string | The name of the connection pool; unique within the instrumented application. In case the connection pool implementation doesn't provide a name, then the [db.connection_string](/docs/database/database-spans.md#connection-level-attributes) should be used | `myDataSource` | Required |
| `pool.name` | string | The name of the connection pool; unique within the instrumented application. In case the connection pool implementation doesn't provide a name, then the [db.connection_string](/docs/database/database-spans.md#common-attributes) should be used | `myDataSource` | Required |
| `state` | string | The state of a connection in the pool | `idle` | Required |

`state` MUST be one of the following:
Expand All @@ -75,7 +75,7 @@ This metric is [recommended][MetricRecommended].
<!-- semconv metric.db.client.connections.idle.max(full) -->
| Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---|
| `pool.name` | string | The name of the connection pool; unique within the instrumented application. In case the connection pool implementation doesn't provide a name, then the [db.connection_string](/docs/database/database-spans.md#connection-level-attributes) should be used | `myDataSource` | Required |
| `pool.name` | string | The name of the connection pool; unique within the instrumented application. In case the connection pool implementation doesn't provide a name, then the [db.connection_string](/docs/database/database-spans.md#common-attributes) should be used | `myDataSource` | Required |
<!-- endsemconv -->

### Metric: `db.client.connections.idle.min`
Expand All @@ -91,7 +91,7 @@ This metric is [recommended][MetricRecommended].
<!-- semconv metric.db.client.connections.idle.min(full) -->
| Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---|
| `pool.name` | string | The name of the connection pool; unique within the instrumented application. In case the connection pool implementation doesn't provide a name, then the [db.connection_string](/docs/database/database-spans.md#connection-level-attributes) should be used | `myDataSource` | Required |
| `pool.name` | string | The name of the connection pool; unique within the instrumented application. In case the connection pool implementation doesn't provide a name, then the [db.connection_string](/docs/database/database-spans.md#common-attributes) should be used | `myDataSource` | Required |
<!-- endsemconv -->

### Metric: `db.client.connections.max`
Expand All @@ -107,7 +107,7 @@ This metric is [recommended][MetricRecommended].
<!-- semconv metric.db.client.connections.max(full) -->
| Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---|
| `pool.name` | string | The name of the connection pool; unique within the instrumented application. In case the connection pool implementation doesn't provide a name, then the [db.connection_string](/docs/database/database-spans.md#connection-level-attributes) should be used | `myDataSource` | Required |
| `pool.name` | string | The name of the connection pool; unique within the instrumented application. In case the connection pool implementation doesn't provide a name, then the [db.connection_string](/docs/database/database-spans.md#common-attributes) should be used | `myDataSource` | Required |
<!-- endsemconv -->

### Metric: `db.client.connections.pending_requests`
Expand All @@ -123,7 +123,7 @@ This metric is [recommended][MetricRecommended].
<!-- semconv metric.db.client.connections.pending_requests(full) -->
| Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---|
| `pool.name` | string | The name of the connection pool; unique within the instrumented application. In case the connection pool implementation doesn't provide a name, then the [db.connection_string](/docs/database/database-spans.md#connection-level-attributes) should be used | `myDataSource` | Required |
| `pool.name` | string | The name of the connection pool; unique within the instrumented application. In case the connection pool implementation doesn't provide a name, then the [db.connection_string](/docs/database/database-spans.md#common-attributes) should be used | `myDataSource` | Required |
<!-- endsemconv -->

### Metric: `db.client.connections.timeouts`
Expand All @@ -139,7 +139,7 @@ This metric is [recommended][MetricRecommended].
<!-- semconv metric.db.client.connections.timeouts(full) -->
| Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---|
| `pool.name` | string | The name of the connection pool; unique within the instrumented application. In case the connection pool implementation doesn't provide a name, then the [db.connection_string](/docs/database/database-spans.md#connection-level-attributes) should be used | `myDataSource` | Required |
| `pool.name` | string | The name of the connection pool; unique within the instrumented application. In case the connection pool implementation doesn't provide a name, then the [db.connection_string](/docs/database/database-spans.md#common-attributes) should be used | `myDataSource` | Required |
<!-- endsemconv -->

### Metric: `db.client.connections.create_time`
Expand All @@ -155,7 +155,7 @@ This metric is [recommended][MetricRecommended].
<!-- semconv metric.db.client.connections.create_time(full) -->
| Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---|
| `pool.name` | string | The name of the connection pool; unique within the instrumented application. In case the connection pool implementation doesn't provide a name, then the [db.connection_string](/docs/database/database-spans.md#connection-level-attributes) should be used | `myDataSource` | Required |
| `pool.name` | string | The name of the connection pool; unique within the instrumented application. In case the connection pool implementation doesn't provide a name, then the [db.connection_string](/docs/database/database-spans.md#common-attributes) should be used | `myDataSource` | Required |
<!-- endsemconv -->

### Metric: `db.client.connections.wait_time`
Expand All @@ -171,7 +171,7 @@ This metric is [recommended][MetricRecommended].
<!-- semconv metric.db.client.connections.wait_time(full) -->
| Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---|
| `pool.name` | string | The name of the connection pool; unique within the instrumented application. In case the connection pool implementation doesn't provide a name, then the [db.connection_string](/docs/database/database-spans.md#connection-level-attributes) should be used | `myDataSource` | Required |
| `pool.name` | string | The name of the connection pool; unique within the instrumented application. In case the connection pool implementation doesn't provide a name, then the [db.connection_string](/docs/database/database-spans.md#common-attributes) should be used | `myDataSource` | Required |
<!-- endsemconv -->

### Metric: `db.client.connections.use_time`
Expand All @@ -187,7 +187,7 @@ This metric is [recommended][MetricRecommended].
<!-- semconv metric.db.client.connections.use_time(full) -->
| Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---|
| `pool.name` | string | The name of the connection pool; unique within the instrumented application. In case the connection pool implementation doesn't provide a name, then the [db.connection_string](/docs/database/database-spans.md#connection-level-attributes) should be used | `myDataSource` | Required |
| `pool.name` | string | The name of the connection pool; unique within the instrumented application. In case the connection pool implementation doesn't provide a name, then the [db.connection_string](/docs/database/database-spans.md#common-attributes) should be used | `myDataSource` | Required |
<!-- endsemconv -->

[DocumentStatus]: https://github.com/open-telemetry/opentelemetry-specification/tree/v1.26.0/specification/document-status.md
Expand Down
Loading
Loading