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

telemetry should happen first #3915

Closed
BrynCooke opened this issue Sep 27, 2023 · 0 comments · Fixed by #3919
Closed

telemetry should happen first #3915

BrynCooke opened this issue Sep 27, 2023 · 0 comments · Fixed by #3919
Assignees

Comments

@BrynCooke
Copy link
Contributor

As the router pipeline has evolved various things have crept in before the telemetry plugin. This means that we may be inaccurate operation counts and spans will be missing some processing time.

apollo.router.operations metric should be moved to the fist thing in the pipeline in factory.

In addition, the make span layer should also move.

@BrynCooke BrynCooke self-assigned this Sep 27, 2023
BrynCooke pushed a commit that referenced this issue Sep 27, 2023
…a throwback from when the router service did not exist.

Move operation count metrics to the first thing that happens in the pipeline.
Note that this won't catch disconnects because they are reliant on the status code of the response, which will stop processing before the metric is incremented.

Fixes #3915
BrynCooke pushed a commit that referenced this issue Sep 27, 2023
Our metrics are currently mutated at the supergraph service. This is a throwback from when the router service did not exist.
Move operation count metrics to the first thing that happens in the pipeline.
Note that this won't catch disconnects because they are reliant on the status code of the response, which will stop processing before the metric is incremented.

Fixes #3915
BrynCooke added a commit that referenced this issue Sep 27, 2023
…line. (#3919)

Our metrics are currently mutated at the supergraph service. 
This is a throwback from when the router service did not exist.

Move operation count metrics to the first thing that happens in the
pipeline. Note that this won't catch disconnects because they are
reliant on the status code of the response, which will stop processing
before the metric is incremented.

This also move the creation of the root span to the just after so that
cors and extensions are traced.

Fixes #3915


<!-- start metadata -->
---

**Checklist**

Complete the checklist (and note appropriate exceptions) before the PR
is marked ready-for-review.

- [ ] Changes are compatible[^1]
- [ ] Documentation[^2] completed
- [ ] Performance impact assessed and acceptable
- Tests added and passing[^3]
    - [ ] Unit Tests
    - [ ] Integration Tests
    - [ ] Manual Tests

**Exceptions**

*Note any exceptions here*

**Notes**

[^1]: It may be appropriate to bring upcoming changes to the attention
of other (impacted) groups. Please endeavour to do this before seeking
PR approval. The mechanism for doing this will vary considerably, so use
your judgement as to how and when to do this.
[^2]: Configuration is an important part of many changes. Where
applicable please try to document configuration examples.
[^3]: Tick whichever testing boxes are applicable. If you are adding
Manual Tests, please document the manual testing (extensively) in the
Exceptions.

---------

Co-authored-by: bryn <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant