Skip to content

Commit

Permalink
Rename to http.resend_count
Browse files Browse the repository at this point in the history
  • Loading branch information
Mateusz Rzeszutek committed Sep 7, 2022
1 parent c4df7e9 commit da61ca0
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 16 deletions.
4 changes: 4 additions & 0 deletions schemas/1.13.0
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ versions:
attribute_map:
net.peer.ip: net.sock.peer.addr
net.host.ip: net.sock.host.addr
# https://github.com/open-telemetry/opentelemetry-specification/pull/2743
- rename_attributes:
attribute_map:
http.retry_count: http.resend_count
1.12.0:
1.11.0:
1.10.0:
Expand Down
8 changes: 4 additions & 4 deletions semantic_conventions/trace/http.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -113,13 +113,13 @@ groups:
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.
- id: retry_count
- id: resend_count
type: int
brief: >
The ordinal number of request re-sending attempt (for any reason, including redirects).
The ordinal number of request resending attempt (for any reason, including redirects).
note: >
The retry count SHOULD be updated each time an HTTP request gets re-sent by the client, regardless of what
was the cause of the re-sending (e.g. redirection, authorization failure, 503 Server Unavailable, network issues,
The resend count SHOULD be updated each time an HTTP request gets resent by the client, regardless of what
was the cause of the resending (e.g. redirection, authorization failure, 503 Server Unavailable, network issues,
or any other).
requirement_level:
recommended: if and only if request was retried.
Expand Down
24 changes: 12 additions & 12 deletions specification/trace/semantic_conventions/http.md
Original file line number Diff line number Diff line change
Expand Up @@ -130,13 +130,13 @@ before any HTTP-redirects that may happen when executing the request.
| Attribute | Type | Description | Examples | Requirement Level |
|---|---|---|---|---|
| `http.url` | string | Full HTTP request URL in the form `scheme://host[:port]/path?query[#fragment]`. Usually the fragment is not transmitted over HTTP, but if it is known, it should be included nevertheless. [1] | `https://www.foo.bar/search?q=OpenTelemetry#SemConv` | Required |
| `http.retry_count` | int | The ordinal number of request re-sending attempt (for any reason, including redirects). [2] | `3` | Recommended: if and only if request was retried. |
| `http.resend_count` | int | The ordinal number of request resending attempt (for any reason, including redirects). [2] | `3` | Recommended: if and only if request was retried. |
| [`net.peer.name`](span-general.md) | string | Host identifier of the ["URI origin"](https://www.rfc-editor.org/rfc/rfc9110.html#name-uri-origin) HTTP request is sent to. [3] | `example.com` | Required |
| [`net.peer.port`](span-general.md) | int | Port identifier of the ["URI origin"](https://www.rfc-editor.org/rfc/rfc9110.html#name-uri-origin) HTTP request is sent to. [4] | `80`; `8080`; `443` | Conditionally Required: [5] |

**[1]:** `http.url` MUST NOT contain credentials passed via URL in form of `https://username:password@www.example.com/`. In such case the attribute's value should be `https://www.example.com/`.

**[2]:** The retry count SHOULD be updated each time an HTTP request gets re-sent by the client, regardless of what was the cause of the re-sending (e.g. redirection, authorization failure, 503 Server Unavailable, network issues, or any other).
**[2]:** The resend count SHOULD be updated each time an HTTP request gets resent by the client, regardless of what was the cause of the resending (e.g. redirection, authorization failure, 503 Server Unavailable, network issues, or any other).

**[3]:** Determined by using the first of the following that applies

Expand Down Expand Up @@ -165,8 +165,8 @@ Retries and redirects cause more than one physical HTTP request to be sent.
A CLIENT span SHOULD be created for each one of these physical requests.
No span is created corresponding to the "logical" (encompassing) request.

For each time an HTTP request is re-sent, the `http.retry_count` attribute SHOULD be added to each retry span
and set to the ordinal number of the request re-send attempt.
Each time an HTTP request is resent, the `http.resend_count` attribute SHOULD be added to each repeated span
and set to the ordinal number of the request resend attempt.

See [examples](#http-client-retries-examples) for more details.

Expand Down Expand Up @@ -336,11 +336,11 @@ request (SERVER, trace=t1, span=s1)
| |
| --- server (SERVER, trace=t1, span=s3)
|
-- GET / - 500 (CLIENT, trace=t1, span=s4, http.retry_count=1)
-- GET / - 500 (CLIENT, trace=t1, span=s4, http.resend_count=1)
| |
| --- server (SERVER, trace=t1, span=s5)
|
-- GET / - 200 (CLIENT, trace=t1, span=s6, http.retry_count=2)
-- GET / - 200 (CLIENT, trace=t1, span=s6, http.resend_count=2)
|
--- server (SERVER, trace=t1, span=s7)
```
Expand All @@ -352,11 +352,11 @@ GET / - 500 (CLIENT, trace=t1, span=s1)
|
--- server (SERVER, trace=t1, span=s2)
GET / - 500 (CLIENT, trace=t2, span=s1, http.retry_count=1)
GET / - 500 (CLIENT, trace=t2, span=s1, http.resend_count=1)
|
--- server (SERVER, trace=t2, span=s2)
GET / - 200 (CLIENT, trace=t3, span=s1, http.retry_count=2)
GET / - 200 (CLIENT, trace=t3, span=s1, http.resend_count=2)
|
--- server (SERVER, trace=t3, span=s1)
```
Expand All @@ -372,7 +372,7 @@ request (SERVER, trace=t1, span=s1)
| |
| --- server (SERVER, trace=t1, span=s3)
|
-- GET /hello - 200 (CLIENT, trace=t1, span=s4, http.retry_count=1)
-- GET /hello - 200 (CLIENT, trace=t1, span=s4, http.resend_count=1)
|
--- server (SERVER, trace=t1, span=s5)
```
Expand All @@ -384,7 +384,7 @@ GET / - 401 (CLIENT, trace=t1, span=s1)
|
--- server (SERVER, trace=t1, span=s2)
GET /hello - 200 (CLIENT, trace=t2, span=s1, http.retry_count=1)
GET /hello - 200 (CLIENT, trace=t2, span=s1, http.resend_count=1)
|
--- server (SERVER, trace=t2, span=s2)
```
Expand All @@ -400,7 +400,7 @@ request (SERVER, trace=t1, span=s1)
| |
| --- server (SERVER, trace=t1, span=s3)
|
-- GET /hello - 200 (CLIENT, trace=t1, span=s4, http.retry_count=1)
-- GET /hello - 200 (CLIENT, trace=t1, span=s4, http.resend_count=1)
|
--- server (SERVER, trace=t1, span=s5)
```
Expand All @@ -412,7 +412,7 @@ GET / - 302 (CLIENT, trace=t1, span=s1)
|
--- server (SERVER, trace=t1, span=s2)
GET /hello - 200 (CLIENT, trace=t2, span=s1, http.retry_count=1)
GET /hello - 200 (CLIENT, trace=t2, span=s1, http.resend_count=1)
|
--- server (SERVER, trace=t2, span=s2)
```

0 comments on commit da61ca0

Please sign in to comment.