Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: add apollo_operation_id #3803

Closed
abernix opened this issue Sep 11, 2023 · 0 comments · Fixed by #5189
Closed

docs: add apollo_operation_id #3803

abernix opened this issue Sep 11, 2023 · 0 comments · Fixed by #5189
Assignees
Labels
documentation Improvements or additions to documentation

Comments

@abernix
Copy link
Member

abernix commented Sep 11, 2023

In #3586, @o0Ignition0o introduced the apollo_operation_id — a user-accessible attribute that can be fetched from the context and used to build a durable link to the Operation page in Studio. This is useful for emitting into logs or, e.g., as an attribute on trace spans for debugging purposes. We may make this available in more places in the future!

Using two other pieces of information from the graph reference (the your-graph@current option that you run your Router with), this new apollo_operation_id value can be used to generate the full URL using the following convention:

https://studio.apollographql.com/graph/{{your_graph_id}}/variant/{{your_graph_variant}}/operations?query={{apollo_operation_id}}

Where:

  • {{your_graph_id}} (This is the part to the left of the @ sign in your "graph reference" (i.e., the your-graph part of your-graph@current)
  • {{your_graph_variant}} (This is the part to the right of the @ sign in your "graph reference" (i.e., the current part of your-graph@current)
  • {{apollo_operation_id}} this is the value read from the context's apollo_operation_id property.

No curly braces should be present in the actual URL. 😄

abernix added a commit that referenced this issue Sep 11, 2023
This corrects the example for #3586 which inadvertently suggested using `<your_graph_variant>` twice instead of `<your_graph_id>` and (separately) `<your_graph_variant>`:

https://studio.apollographql.com/graph/<your_graph_id>/variant/<your_graph_variant>/operations?query=<apollo_operation_id>

This doesn't replace the need to document this in #3803. 😄
@abernix abernix added the documentation Improvements or additions to documentation label Sep 11, 2023
abernix added a commit that referenced this issue Sep 12, 2023
This corrects the CHANGELOG entry for #3586 which inadvertently
suggested using `<your_graph_variant>` twice instead of
`<your_graph_id>` and (separately) `<your_graph_variant>`:

```
https://studio.apollographql.com/graph/<your_graph_id>/variant/<your_graph_variant>/operations?query=<apollo_operation_id>
```

This doesn't replace the need to document this in
#3803. 😄
garypen pushed a commit that referenced this issue Sep 12, 2023
This corrects the CHANGELOG entry for #3586 which inadvertently
suggested using `<your_graph_variant>` twice instead of
`<your_graph_id>` and (separately) `<your_graph_variant>`:

```
https://studio.apollographql.com/graph/<your_graph_id>/variant/<your_graph_variant>/operations?query=<apollo_operation_id>
```

This doesn't replace the need to document this in
#3803. 😄
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants