Skip to content

Commit

Permalink
Update client address to be consistent with server address (#302)
Browse files Browse the repository at this point in the history
Co-authored-by: Armin Ruech <[email protected]>
  • Loading branch information
trask and arminru authored Sep 12, 2023
1 parent 48dc44c commit 58c52c5
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 4 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ release.
([#270](https://github.com/open-telemetry/semantic-conventions/pull/270))
- Moved RPC streaming notes from metric brief section to notes section.
([#275](https://github.com/open-telemetry/semantic-conventions/pull/275))
- Updates `client.address` to allow domain names for consistency with `server.address`.
([#302](https://github.com/open-telemetry/semantic-conventions/pull/302))
- BREAKING: Generate System metrics semconv from YAML.
([#89](https://github.com/open-telemetry/semantic-conventions/pull/89))
- Rename attributes for `system.cpu.*` metrics:
Expand Down
2 changes: 1 addition & 1 deletion docs/general/attributes.md
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ if they do not cause breaking changes to HTTP semantic conventions.
<!-- semconv client -->
| Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---|
| `client.address` | string | Client address - IP address or Unix domain socket name. [1] | `/tmp/my.sock`; `10.1.2.80` | Recommended |
| `client.address` | string | Client address - domain name if available without reverse DNS lookup, otherwise IP address or Unix domain socket name. [1] | `/tmp/my.sock`; `10.1.2.80` | Recommended |
| `client.port` | int | Client port number. [2] | `65123` | Recommended |
| `client.socket.address` | string | Client address of the socket connection - IP address or Unix domain socket name. [3] | `/tmp/my.sock`; `127.0.0.1` | Recommended: If different than `client.address`. |
| `client.socket.port` | int | Client port number of the socket connection. [4] | `35555` | Recommended: If different than `client.port`. |
Expand Down
2 changes: 1 addition & 1 deletion docs/http/http-spans.md
Original file line number Diff line number Diff line change
Expand Up @@ -376,7 +376,7 @@ If the route cannot be determined, the `name` attribute MUST be set as defined i
| Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---|
| `http.route` | string | The matched route (path template in the format used by the respective server framework). See note below [1] | `/users/:userID?`; `{controller}/{action}/{id?}` | Conditionally Required: If and only if it's available |
| [`client.address`](../general/attributes.md) | string | Client address - IP address or Unix domain socket name. [2] | `83.164.160.102` | Recommended |
| [`client.address`](../general/attributes.md) | string | Client address - domain name if available without reverse DNS lookup, otherwise IP address or Unix domain socket name. [2] | `83.164.160.102` | Recommended |
| [`client.port`](../general/attributes.md) | int | The port of the original client behind all proxies, if known (e.g. from [Forwarded](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Forwarded) or a similar header). Otherwise, the immediate client peer port. [3] | `65123` | Recommended |
| [`client.socket.address`](../general/attributes.md) | string | Client address of the socket connection - IP address or Unix domain socket name. [4] | `/tmp/my.sock`; `127.0.0.1` | Recommended: If different than `client.address`. |
| [`client.socket.port`](../general/attributes.md) | int | Client port number of the socket connection. [5] | `35555` | Recommended: If different than `client.port`. |
Expand Down
2 changes: 1 addition & 1 deletion docs/rpc/rpc-spans.md
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ Generally, a user SHOULD NOT set `peer.service` to a fully qualified RPC service
<!-- semconv rpc.server -->
| Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---|
| [`client.address`](../general/attributes.md) | string | Client address - IP address or Unix domain socket name. [1] | `/tmp/my.sock`; `10.1.2.80` | Recommended |
| [`client.address`](../general/attributes.md) | string | Client address - domain name if available without reverse DNS lookup, otherwise IP address or Unix domain socket name. [1] | `/tmp/my.sock`; `10.1.2.80` | Recommended |
| [`client.port`](../general/attributes.md) | int | Client port number. [2] | `65123` | Recommended |
| [`client.socket.address`](../general/attributes.md) | string | Client address of the socket connection - IP address or Unix domain socket name. [3] | `/tmp/my.sock`; `127.0.0.1` | Recommended: If different than `client.address`. |
| [`client.socket.port`](../general/attributes.md) | int | Client port number of the socket connection. [4] | `35555` | Recommended: If different than `client.port`. |
Expand Down
2 changes: 1 addition & 1 deletion model/client.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ groups:
attributes:
- id: address
type: string
brief: Client address - IP address or Unix domain socket name.
brief: Client address - domain name if available without reverse DNS lookup, otherwise IP address or Unix domain socket name.
note: >
When observed from the server side, and when communicating through an intermediary, `client.address` SHOULD represent
the client address behind any intermediaries (e.g. proxies) if it's available.
Expand Down

0 comments on commit 58c52c5

Please sign in to comment.