forked from open-telemetry/opentelemetry-specification
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add http metrics yaml (open-telemetry#3158)
* Add http metrics yaml * Update change log * Fix notes * Fix link * Remove unnecessary field
- Loading branch information
Showing
3 changed files
with
558 additions
and
44 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,283 @@ | ||
groups: | ||
- id: metric.http.server.duration | ||
type: metric | ||
metric_name: http.server.duration | ||
brief: "Measures the duration of inbound HTTP requests." | ||
instrument: histogram | ||
unit: "ms" | ||
attributes: | ||
- ref: http.method | ||
requirement_level: required | ||
- ref: http.scheme | ||
requirement_level: required | ||
- ref: http.route | ||
requirement_level: | ||
conditionally_required: If and only if it's available | ||
- ref: http.status_code | ||
requirement_level: | ||
conditionally_required: If and only if one was received/sent. | ||
- ref: http.flavor | ||
- ref: net.host.name | ||
requirement_level: required | ||
brief: > | ||
Name of the local HTTP server that received the request. | ||
note: | | ||
Determined by using the first of the following that applies | ||
- The [primary server name](../../trace/semantic_conventions/http.md#http-server-definitions) of the matched virtual host. MUST only | ||
include host identifier. | ||
- Host identifier of the [request target](https://www.rfc-editor.org/rfc/rfc9110.html#target.resource) | ||
if it's sent in absolute-form. | ||
- Host identifier of the `Host` header | ||
SHOULD NOT be set if only IP address is available and capturing name would require a reverse DNS lookup. | ||
- ref: net.host.port | ||
requirement_level: | ||
conditionally_required: If not default (`80` for `http` scheme, `443` for `https`). | ||
brief: > | ||
Port of the local HTTP server that received the request. | ||
note: | | ||
Determined by using the first of the following that applies | ||
- Port identifier of the [primary server host](../../trace/semantic_conventions/http.md#http-server-definitions) of the matched virtual host. | ||
- Port identifier of the [request target](https://www.rfc-editor.org/rfc/rfc9110.html#target.resource) | ||
if it's sent in absolute-form. | ||
- Port identifier of the `Host` header | ||
- id: metric.http.server.active_requests | ||
type: metric | ||
metric_name: http.server.active_requests | ||
brief: "Measures the number of concurrent HTTP requests that are currently in-flight." | ||
instrument: updowncounter | ||
unit: "{requests}" | ||
attributes: | ||
- ref: http.method | ||
requirement_level: required | ||
- ref: http.scheme | ||
requirement_level: required | ||
- ref: http.flavor | ||
- ref: net.host.name | ||
requirement_level: required | ||
brief: > | ||
Name of the local HTTP server that received the request. | ||
note: | | ||
Determined by using the first of the following that applies | ||
- The [primary server name](../../trace/semantic_conventions/http.md#http-server-definitions) of the matched virtual host. MUST only | ||
include host identifier. | ||
- Host identifier of the [request target](https://www.rfc-editor.org/rfc/rfc9110.html#target.resource) | ||
if it's sent in absolute-form. | ||
- Host identifier of the `Host` header | ||
SHOULD NOT be set if only IP address is available and capturing name would require a reverse DNS lookup. | ||
- ref: net.host.port | ||
requirement_level: | ||
conditionally_required: If not default (`80` for `http` scheme, `443` for `https`). | ||
brief: > | ||
Port of the local HTTP server that received the request. | ||
note: | | ||
Determined by using the first of the following that applies | ||
- Port identifier of the [primary server host](../../trace/semantic_conventions/http.md#http-server-definitions) of the matched virtual host. | ||
- Port identifier of the [request target](https://www.rfc-editor.org/rfc/rfc9110.html#target.resource) | ||
if it's sent in absolute-form. | ||
- Port identifier of the `Host` header | ||
- id: metric.http.server.request.size | ||
type: metric | ||
metric_name: http.server.request.size | ||
brief: "Measures the size of HTTP request messages (compressed)." | ||
instrument: histogram | ||
unit: "By" | ||
# TODO (trask) below attributes are identical to above in metric.http.server.duration | ||
attributes: | ||
- ref: http.method | ||
requirement_level: required | ||
- ref: http.scheme | ||
requirement_level: required | ||
- ref: http.route | ||
requirement_level: | ||
conditionally_required: If and only if it's available | ||
- ref: http.status_code | ||
requirement_level: | ||
conditionally_required: If and only if one was received/sent. | ||
- ref: http.flavor | ||
- ref: net.host.name | ||
requirement_level: required | ||
brief: > | ||
Name of the local HTTP server that received the request. | ||
note: | | ||
Determined by using the first of the following that applies | ||
- The [primary server name](../../trace/semantic_conventions/http.md#http-server-definitions) of the matched virtual host. MUST only | ||
include host identifier. | ||
- Host identifier of the [request target](https://www.rfc-editor.org/rfc/rfc9110.html#target.resource) | ||
if it's sent in absolute-form. | ||
- Host identifier of the `Host` header | ||
SHOULD NOT be set if only IP address is available and capturing name would require a reverse DNS lookup. | ||
- ref: net.host.port | ||
requirement_level: | ||
conditionally_required: If not default (`80` for `http` scheme, `443` for `https`). | ||
brief: > | ||
Port of the local HTTP server that received the request. | ||
note: | | ||
Determined by using the first of the following that applies | ||
- Port identifier of the [primary server host](../../trace/semantic_conventions/http.md#http-server-definitions) of the matched virtual host. | ||
- Port identifier of the [request target](https://www.rfc-editor.org/rfc/rfc9110.html#target.resource) | ||
if it's sent in absolute-form. | ||
- Port identifier of the `Host` header | ||
- id: metric.http.server.response.size | ||
type: metric | ||
metric_name: http.server.response.size | ||
brief: "Measures the size of HTTP response messages (compressed)." | ||
instrument: histogram | ||
unit: "By" | ||
# TODO (trask) below attributes are identical to above in metric.http.server.duration | ||
attributes: | ||
- ref: http.method | ||
requirement_level: required | ||
- ref: http.scheme | ||
requirement_level: required | ||
- ref: http.route | ||
requirement_level: | ||
conditionally_required: If and only if it's available | ||
- ref: http.status_code | ||
requirement_level: | ||
conditionally_required: If and only if one was received/sent. | ||
- ref: http.flavor | ||
- ref: net.host.name | ||
requirement_level: required | ||
brief: > | ||
Name of the local HTTP server that received the request. | ||
note: | | ||
Determined by using the first of the following that applies | ||
- The [primary server name](../../trace/semantic_conventions/http.md#http-server-definitions) of the matched virtual host. MUST only | ||
include host identifier. | ||
- Host identifier of the [request target](https://www.rfc-editor.org/rfc/rfc9110.html#target.resource) | ||
if it's sent in absolute-form. | ||
- Host identifier of the `Host` header | ||
SHOULD NOT be set if only IP address is available and capturing name would require a reverse DNS lookup. | ||
- ref: net.host.port | ||
requirement_level: | ||
conditionally_required: If not default (`80` for `http` scheme, `443` for `https`). | ||
brief: > | ||
Port of the local HTTP server that received the request. | ||
note: | | ||
Determined by using the first of the following that applies | ||
- Port identifier of the [primary server host](../../trace/semantic_conventions/http.md#http-server-definitions) of the matched virtual host. | ||
- Port identifier of the [request target](https://www.rfc-editor.org/rfc/rfc9110.html#target.resource) | ||
if it's sent in absolute-form. | ||
- Port identifier of the `Host` header | ||
- id: metric.http.client.duration | ||
type: metric | ||
metric_name: http.client.duration | ||
brief: "Measures the duration of outbound HTTP requests." | ||
instrument: histogram | ||
unit: "ms" | ||
attributes: | ||
- ref: http.method | ||
requirement_level: required | ||
- ref: http.status_code | ||
requirement_level: | ||
conditionally_required: If and only if one was received/sent. | ||
- ref: http.flavor | ||
- ref: net.peer.name | ||
requirement_level: required | ||
brief: > | ||
Host identifier of the ["URI origin"](https://www.rfc-editor.org/rfc/rfc9110.html#name-uri-origin) HTTP request is sent to. | ||
note: | | ||
Determined by using the first of the following that applies | ||
- Host identifier of the [request target](https://www.rfc-editor.org/rfc/rfc9110.html#target.resource) | ||
if it's sent in absolute-form | ||
- Host identifier of the `Host` header | ||
SHOULD NOT be set if capturing it would require an extra DNS lookup. | ||
- ref: net.peer.port | ||
requirement_level: | ||
conditionally_required: If not default (`80` for `http` scheme, `443` for `https`). | ||
brief: > | ||
Port identifier of the ["URI origin"](https://www.rfc-editor.org/rfc/rfc9110.html#name-uri-origin) HTTP request is sent to. | ||
note: > | ||
When [request target](https://www.rfc-editor.org/rfc/rfc9110.html#target.resource) is absolute URI, `net.peer.name` MUST match | ||
URI port identifier, otherwise it MUST match `Host` header port identifier. | ||
- ref: net.sock.peer.addr | ||
|
||
- id: metric.http.client.request.size | ||
type: metric | ||
metric_name: http.client.request.size | ||
brief: "Measures the size of HTTP request messages (compressed)." | ||
instrument: histogram | ||
unit: "By" | ||
# TODO (trask) below attributes are identical to above in metric.http.client.duration | ||
attributes: | ||
- ref: http.method | ||
requirement_level: required | ||
- ref: http.status_code | ||
requirement_level: | ||
conditionally_required: If and only if one was received/sent. | ||
- ref: http.flavor | ||
- ref: net.peer.name | ||
requirement_level: required | ||
brief: > | ||
Host identifier of the ["URI origin"](https://www.rfc-editor.org/rfc/rfc9110.html#name-uri-origin) HTTP request is sent to. | ||
note: | | ||
Determined by using the first of the following that applies | ||
- Host identifier of the [request target](https://www.rfc-editor.org/rfc/rfc9110.html#target.resource) | ||
if it's sent in absolute-form | ||
- Host identifier of the `Host` header | ||
SHOULD NOT be set if capturing it would require an extra DNS lookup. | ||
- ref: net.peer.port | ||
requirement_level: | ||
conditionally_required: If not default (`80` for `http` scheme, `443` for `https`). | ||
brief: > | ||
Port identifier of the ["URI origin"](https://www.rfc-editor.org/rfc/rfc9110.html#name-uri-origin) HTTP request is sent to. | ||
note: > | ||
When [request target](https://www.rfc-editor.org/rfc/rfc9110.html#target.resource) is absolute URI, `net.peer.name` MUST match | ||
URI port identifier, otherwise it MUST match `Host` header port identifier. | ||
- ref: net.sock.peer.addr | ||
|
||
- id: metric.http.client.response.size | ||
type: metric | ||
metric_name: http.client.response.size | ||
brief: "Measures the size of HTTP response messages (compressed)." | ||
instrument: histogram | ||
unit: "By" | ||
# TODO (trask) below attributes are identical to above in metric.http.client.duration | ||
attributes: | ||
- ref: http.method | ||
requirement_level: required | ||
- ref: http.status_code | ||
requirement_level: | ||
conditionally_required: If and only if one was received/sent. | ||
- ref: http.flavor | ||
- ref: net.peer.name | ||
requirement_level: required | ||
brief: > | ||
Host identifier of the ["URI origin"](https://www.rfc-editor.org/rfc/rfc9110.html#name-uri-origin) HTTP request is sent to. | ||
note: | | ||
Determined by using the first of the following that applies | ||
- Host identifier of the [request target](https://www.rfc-editor.org/rfc/rfc9110.html#target.resource) | ||
if it's sent in absolute-form | ||
- Host identifier of the `Host` header | ||
SHOULD NOT be set if capturing it would require an extra DNS lookup. | ||
- ref: net.peer.port | ||
requirement_level: | ||
conditionally_required: If not default (`80` for `http` scheme, `443` for `https`). | ||
brief: > | ||
Port identifier of the ["URI origin"](https://www.rfc-editor.org/rfc/rfc9110.html#name-uri-origin) HTTP request is sent to. | ||
note: > | ||
When [request target](https://www.rfc-editor.org/rfc/rfc9110.html#target.resource) is absolute URI, `net.peer.name` MUST match | ||
URI port identifier, otherwise it MUST match `Host` header port identifier. | ||
- ref: net.sock.peer.addr |
Oops, something went wrong.