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

Add debug spans for codec tracing #1759

Open
neoeinstein opened this issue Jun 26, 2024 · 0 comments · May be fixed by #1760
Open

Add debug spans for codec tracing #1759

neoeinstein opened this issue Jun 26, 2024 · 0 comments · May be fixed by #1760

Comments

@neoeinstein
Copy link
Contributor

Feature Request

Crates

tonic

Motivation

We've had some clients that have, for some reason, been really slow at sending up body bytes. This would be easier to confirm if we could see that the decoding process was taking up a certain amount of time, and could be done by providing some tracing spans at the debug level that could be enabled to expose the time spend in request decoding, which often spends some time waiting for data to arrive over the wire.

Proposal

Add some tracing debug spans for the codecs so that consumers can use tracing to identify potential stalls in decoding of a request. This could add a bit more weight to the state of the decoder, but the overall cost is generally a couple of bytes per connection, and if debug spans aren't enabled, these will always be disabled values.

Alternatives

The only other option has been inference, but the time spent here is difficult to separate out from other causes.

neoeinstein added a commit to neoeinstein/tonic that referenced this issue Jun 26, 2024
neoeinstein added a commit to neoeinstein/tonic that referenced this issue Jun 26, 2024
neoeinstein added a commit to neoeinstein/tonic that referenced this issue Jun 26, 2024
neoeinstein added a commit to neoeinstein/tonic that referenced this issue Jun 26, 2024
neoeinstein added a commit to neoeinstein/tonic that referenced this issue Jun 26, 2024
neoeinstein added a commit to neoeinstein/tonic that referenced this issue Jun 26, 2024
neoeinstein added a commit to neoeinstein/tonic that referenced this issue Jun 26, 2024
neoeinstein added a commit to neoeinstein/tonic that referenced this issue Jun 26, 2024
neoeinstein added a commit to neoeinstein/tonic that referenced this issue Jun 26, 2024
neoeinstein added a commit to neoeinstein/tonic that referenced this issue Jun 26, 2024
neoeinstein added a commit to neoeinstein/tonic that referenced this issue Jun 26, 2024
@neoeinstein neoeinstein linked a pull request Jun 26, 2024 that will close this issue
neoeinstein added a commit to neoeinstein/tonic that referenced this issue Jun 26, 2024
neoeinstein added a commit to neoeinstein/tonic that referenced this issue Jun 27, 2024
neoeinstein added a commit to neoeinstein/tonic that referenced this issue Jun 28, 2024
neoeinstein added a commit to neoeinstein/tonic that referenced this issue Jun 28, 2024
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