Skip to content
This repository has been archived by the owner on Aug 14, 2024. It is now read-only.

Commit

Permalink
Update requests.mdx (#1332)
Browse files Browse the repository at this point in the history
  • Loading branch information
cleptric authored Jul 10, 2024
1 parent bf34a3b commit 5abf76a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/docs/sdk/performance/modules/requests.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@ The SDK should auto-instrument all outgoing HTTP requests, regardless of the lib
| Attribute | Description | Notes |
|:--|:--|:--|
| `op` | Always `"http.client"` | Required |
| `description` | A string including the HTTP request method, and the full URL. e.g., `"GET https://example.com/data.json"` | Required [^1] |
| `description` | A string including the HTTP request method, and the partial URL. e.g., `"GET https://example.com/data.json"` | Required [^1] |
| `data` | A key-value mapping of span attributes. (e.g., `{"http.query": "filter=all", "server.address": "prod-2.example.com"}`) | Required for full experience. See [Span Data](#span-data) for details |

### Span Data

None of the span data fields are hard requirements, but attaching as many of them as possible is a more future-proof approach. We recommend that the SDK adds every attribute listed in the [HTTP Span Data Conventions](/sdk/performance/span-data-conventions/#http). The minimal requirements are:

- `server.address` must be set to allow correct domain grouping _for descriptions containing relative URLs_. e.g., the description `"GET /data.json"` is missing a domain. In this case, `server.address` must be set. If the span description contains the full URL, `span.server` can be omitted
- `server.address` must be set to allow correct domain grouping _for descriptions containing relative URLs_. e.g., the description `"GET /data.json"` is missing a domain. In this case, `server.address` must be set. If the span description contains the partial URL, `span.server` can be omitted
- `http.response.status_code` must be set to enable response code breakdowns

## Instrumentation Example
Expand Down

0 comments on commit 5abf76a

Please sign in to comment.