Skip to content

Commit

Permalink
add a disclaimer for advanced telemetry (#5051)
Browse files Browse the repository at this point in the history
  • Loading branch information
bnjjj authored Apr 30, 2024
1 parent 3781cd7 commit 3d4c1e1
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
2 changes: 2 additions & 0 deletions docs/shared/telemetry-performance.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,5 @@ Keep in mind that the amount of telemetry you add can impact your router's perfo

- Custom metrics, events, and attributes consume more processing resources than standard metrics. Adding too many (standard or custom) can slow your router down.
- Configurations such as `events.*.request|error|response` that produce output for all router lifecycle services should only be used for development or debugging, not for production.

For properly logged telemetry, you should use a log verbosity of `info`. Set the values of `RUST_LOG` or `APOLLO_ROUTER_LOG` environment variables and the `--log` CLI option to `info`. Using less verbose logging, such as `error`, can cause some attributes to be dropped.
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,9 @@ The supergraph service is executed after query parsing but before query executio

| Selector | Defaultable | Values | Description |
|--------------------|-------------|-------------------------------------|--------------------------------------|
| `operation_name` | Yes | | The operation name from the query |
| `operation_name` | Yes | `string`|`hash` | The operation name from the query |
| `operation_kind` | No | `string` | The operation kind from the query |
| `query` | Yes | `string` | The graphql query |
| `query` | Yes | `string` | The graphql query |
| `query_variable` | Yes | | The name of a graphql query variable |
| `request_header` | Yes | | The name of a request header |
| `response_header` | Yes | | The name of a response header |
Expand All @@ -67,18 +67,18 @@ The subgraph service executes multiple times during query execution, with each e

| Selector | Defaultable | Values | Description |
|-----------------------------|-------------|-------------------------------------|---------------------------------------------------------------------------------|
| `subgraph_operation_name` | Yes | | The operation name from the subgraph query |
| `subgraph_operation_name` | Yes | `string`|`hash` | The operation name from the subgraph query |
| `subgraph_operation_kind` | No | `string` | The operation kind from the subgraph query |
| `subgraph_query` | Yes | | The graphql query to the subgraph |
| `subgraph_query` | Yes | `string` | The graphql query to the subgraph |
| `subgraph_query_variable` | Yes | | The name of a subgraph query variable |
| `subgraph_response_data` | Yes | | Json Path into the subgraph response body data (it might impact performances) |
| `subgraph_response_errors` | Yes | | Json Path into the subgraph response body errors (it might impact performances) |
| `subgraph_request_header` | Yes | | The name of a subgraph request header |
| `subgraph_response_header` | Yes | | The name of a subgraph response header |
| `subgraph_response_status` | Yes | `code`\|`reason` | The status of a subgraph response |
| `supergraph_operation_name` | Yes | | The operation name from the supergraph query |
| `supergraph_operation_name` | Yes | `string`|`hash` | The operation name from the supergraph query |
| `supergraph_operation_kind` | Yes | `string` | The operation kind from the supergraph query |
| `supergraph_query` | Yes | | The graphql query to the supergraph |
| `supergraph_query` | Yes | `string` | The graphql query to the supergraph |
| `supergraph_query_variable` | Yes | | The name of a supergraph query variable |
| `request_context` | Yes | | The name of a request context key |
| `response_context` | Yes | | The name of a response context key |
Expand Down

0 comments on commit 3d4c1e1

Please sign in to comment.