Skip to content

Commit

Permalink
suggest connection.state -> http.connection.state and some nits
Browse files Browse the repository at this point in the history
  • Loading branch information
lmolkova committed Jul 27, 2023
1 parent 8fe5865 commit 313dbaf
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 15 deletions.
2 changes: 0 additions & 2 deletions docs/dotnet/dotnet-aspnet-metrics.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,6 @@ This document defines semantic conventions for ASP.NET Core metrics, not specifi

### Metric: `aspnet.unhandled_requests`

**TODO:Any chance we will need to report any attributes in future?**

<!-- semconv metric.aspnet.unhandled_requests(metric_table) -->
| Name | Instrument Type | Unit (UCUM) | Description |
| -------- | --------------- | ----------- | -------------- |
Expand Down
10 changes: 4 additions & 6 deletions docs/dotnet/dotnet-http-metrics.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,18 +37,16 @@ All Http client metrics are reported by `System.Net.Http` meter.
<!-- semconv metric.dotnet.http.client.open_connections(full) -->
| Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---|
| `connection.state` | string | Connection state. [1] | `active`; `idle` | Required |
| [`network.protocol.version`](../general/attributes.md) | string | Version of the application layer protocol used. See note below. [2] | `3.1.1` | Recommended |
| `http.connection.state` | string | State of HTTP connection in the connection pool. | `active`; `idle` | Required |
| [`network.protocol.version`](../general/attributes.md) | string | Version of the application layer protocol used. See note below. [1] | `3.1.1` | Recommended |
| [`server.address`](../general/attributes.md) | string | Logical server hostname, matches server FQDN if available, and IP or socket address if FQDN is not known. | `example.com` | Recommended |
| [`server.port`](../general/attributes.md) | int | Logical server port number | `80`; `8080`; `443` | Recommended |
| [`server.socket.address`](../general/attributes.md) | string | Physical server IP address or Unix socket address. If set from the client, should simply use the socket's peer address, and not attempt to find any actual server IP (i.e., if set from client, this may represent some proxy server instead of the logical server). | `10.5.3.2` | Recommended: If different than `server.address`. |
| [`url.scheme`](../url/url.md) | string | The [URI scheme](https://www.rfc-editor.org/rfc/rfc3986#section-3.1) component identifying the used protocol. | `https`; `ftp`; `telnet` | Recommended |

**[1]:** **TODO: need a prefix?**

**[2]:** `network.protocol.version` refers to the version of the protocol used and might be different from the protocol client's version. If the HTTP client used has a version of `0.27.2`, but sends HTTP version `1.1`, this attribute should be set to `1.1`.
**[1]:** `network.protocol.version` refers to the version of the protocol used and might be different from the protocol client's version. If the HTTP client used has a version of `0.27.2`, but sends HTTP version `1.1`, this attribute should be set to `1.1`.

`connection.state` MUST be one of the following:
`http.connection.state` MUST be one of the following:

| Value | Description |
|---|---|
Expand Down
2 changes: 0 additions & 2 deletions docs/dotnet/dotnet-kestrel-metrics.md
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,6 @@ This document defines semantic conventions for Kestrel web server.

**[1]:** Connections are rejected when the currently active count exceeds the value configured with MaxConcurrentConnections.
Meter name is `Microsoft.AspNetCore.Server.Kestrel`

**TODO: do we ever will have other rejection reasons**
<!-- endsemconv -->

<!-- semconv metric.aspnet.kestrel.rejected_connections(full) -->
Expand Down
5 changes: 2 additions & 3 deletions model/metrics/dotnet-http.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ groups:
note:
Corresponding `EventCounter` names are `*-connections-current-total`; Meter name is `System.Net.Http`.
attributes:
- id: connection.state
- id: http.connection.state
type:
members:
- id: active
Expand All @@ -78,10 +78,9 @@ groups:
- id: idle
value: "idle"
brief: 'idle state.'
brief: Connection state.
brief: State of HTTP connection in the HTTP connection pool.
requirement_level: required
examples: ["active", "idle"]
note: "**TODO: need a prefix?**"
- ref: url.scheme
- ref: network.protocol.version
- ref: server.address
Expand Down
2 changes: 0 additions & 2 deletions model/metrics/dotnet-kestrel.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,6 @@ groups:
note: |
Connections are rejected when the currently active count exceeds the value configured with MaxConcurrentConnections.
Meter name is `Microsoft.AspNetCore.Server.Kestrel`
**TODO: do we ever will have other rejection reasons**
attributes:
- ref: aspnet.kestrel.endpoint

Expand Down

0 comments on commit 313dbaf

Please sign in to comment.