Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/main' into forwarded-server-ad…
Browse files Browse the repository at this point in the history
…dress-port
  • Loading branch information
trask committed Oct 18, 2023
2 parents a189837 + aebcb07 commit 85a97ce
Show file tree
Hide file tree
Showing 14 changed files with 110 additions and 91 deletions.
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,22 @@ release.

- BREAKING: Rename http.resend_count to http.request.resend_count.
([#374](https://github.com/open-telemetry/semantic-conventions/pull/374))
- BREAKING: Change `network.protocol.name` from recommended to opt-in in HTTP semconv.
([#398](https://github.com/open-telemetry/semantic-conventions/pull/398))
- BREAKING: Define url.scheme in terms of logical operation in HTTP server semconv.
([#376](https://github.com/open-telemetry/semantic-conventions/pull/376))
- BREAKING: Change `network.transport` from recommended to opt-in in HTTP semconv.
([#402](https://github.com/open-telemetry/semantic-conventions/pull/402))
- BREAKING: Change `network.type` from recommended to opt-in in HTTP semconv.
([#410](https://github.com/open-telemetry/semantic-conventions/pull/410))
- BREAKING: Factor in `X-Forwarded-Host` / `Forwarded` when capturing `server.address` and `server.port`.
([#411](https://github.com/open-telemetry/semantic-conventions/pull/411))

### Features

- Metric namespaces SHOULD NOT be pluralized.
([#267](https://github.com/open-telemetry/opentelemetry-specification/pull/267))

### Fixes

- Clarify that `error.type` should be the fully-qualified exception class name
Expand All @@ -31,6 +38,8 @@ release.
([#399](https://github.com/open-telemetry/semantic-conventions/pull/399))
- Add cardinality warning about two opt-in HTTP metric attributes to all HTTP metrics.
([#412](https://github.com/open-telemetry/semantic-conventions/pull/412))
- Remove outdated note about not recording HTTP `server.address` when only IP address available.
([#413](https://github.com/open-telemetry/semantic-conventions/pull/413))

## v1.22.0 (2023-10-12)

Expand Down
1 change: 1 addition & 0 deletions docs/attributes-registry/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,6 @@ All registered attributes are listed by namespace in this registry.
Currently, the following namespaces exist:

* [HTTP](http.md)
* [URL](url.md)

[developers recommendations]: https://github.com/open-telemetry/opentelemetry-specification/tree/v1.26.0/specification/common/attribute-naming.md#recommendations-for-application-developers
24 changes: 24 additions & 0 deletions docs/attributes-registry/url.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
<!--- Hugo front matter used to generate the website version of this page:
linkTitle: URL
--->
# URL

## URL Attributes

<!-- semconv registry.url(omit_requirement_level) -->
| Attribute | Type | Description | Examples |
|---|---|---|---|
| `url.fragment` | string | The [URI fragment](https://www.rfc-editor.org/rfc/rfc3986#section-3.5) component | `SemConv` |
| `url.full` | string | Absolute URL describing a network resource according to [RFC3986](https://www.rfc-editor.org/rfc/rfc3986) [1] | `https://www.foo.bar/search?q=OpenTelemetry#SemConv`; `//localhost` |
| `url.path` | string | The [URI path](https://www.rfc-editor.org/rfc/rfc3986#section-3.3) component [2] | `/search` |
| `url.query` | string | The [URI query](https://www.rfc-editor.org/rfc/rfc3986#section-3.4) component [3] | `q=OpenTelemetry` |
| `url.scheme` | string | The [URI scheme](https://www.rfc-editor.org/rfc/rfc3986#section-3.1) component identifying the used protocol. | `https`; `ftp`; `telnet` |

**[1]:** For network calls, URL usually has `scheme://host[:port][path][?query][#fragment]` format, where the fragment is not transmitted over HTTP, but if it is known, it should be included nevertheless.
`url.full` MUST NOT contain credentials passed via URL in form of `https://username:password@www.example.com/`. In such case username and password should be redacted and attribute's value should be `https://REDACTED:REDACTED@www.example.com/`.
`url.full` SHOULD capture the absolute URL when it is available (or can be reconstructed) and SHOULD NOT be validated or modified except for sanitizing purposes.

**[2]:** When missing, the value is assumed to be `/`

**[3]:** Sensitive content provided in query string SHOULD be scrubbed when instrumentations can identify it.
<!-- endsemconv -->
2 changes: 1 addition & 1 deletion docs/database/elasticsearch.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ If the endpoint id is not available, the span name SHOULD be the `http.request.m
| [`http.request.method`](../attributes-registry/http.md) | string | HTTP request method. [6] | `GET`; `POST`; `HEAD` | Required |
| [`server.address`](../general/attributes.md) | string | Name of the database host. [7] | `example.com`; `10.1.2.80`; `/tmp/my.sock` | Recommended |
| [`server.port`](../general/attributes.md) | int | Server port number. [8] | `80`; `8080`; `443` | Conditionally Required: [9] |
| [`url.full`](../url/url.md) | string | Absolute URL describing a network resource according to [RFC3986](https://www.rfc-editor.org/rfc/rfc3986) [10] | `https://localhost:9200/index/_search?q=user.id:kimchy` | Required |
| [`url.full`](../attributes-registry/url.md) | string | Absolute URL describing a network resource according to [RFC3986](https://www.rfc-editor.org/rfc/rfc3986) [10] | `https://localhost:9200/index/_search?q=user.id:kimchy` | Required |

**[1]:** When communicating with an Elastic Cloud deployment, this should be collected from the "X-Found-Handling-Cluster" HTTP response header.

Expand Down
2 changes: 2 additions & 0 deletions docs/general/metrics.md
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,8 @@ using the OpenMetrics exposition format, use the

#### Pluralization

Metric namespaces SHOULD NOT be pluralized.

Metric names SHOULD NOT be pluralized, unless the value being recorded
represents discrete instances of a
[countable quantity](https://en.wikipedia.org/wiki/Count_noun).
Expand Down
Loading

0 comments on commit 85a97ce

Please sign in to comment.