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

contextutil: RunWithTimeout error message is misleading #79424

Closed
erikgrinaker opened this issue Apr 5, 2022 · 0 comments · Fixed by #79767
Closed

contextutil: RunWithTimeout error message is misleading #79424

erikgrinaker opened this issue Apr 5, 2022 · 0 comments · Fixed by #79767
Assignees
Labels
C-bug Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior.

Comments

@erikgrinaker
Copy link
Contributor

erikgrinaker commented Apr 5, 2022

contextutil.RunWithTimeout gives error messages like:

operation "send-snapshot" timed out after 1h0m0s (took 10s): ‹rpc error: code = DeadlineExceeded desc = context deadline exceeded›

Where 1h0m0s is the timeout passed to RunWithTimeout(). However, this is misleading, because either the caller or callee can have set their own context timeout that is smaller than the timeout given to RunWithTimeout.

This is even worse in older releases, where the "(took 10s)" part is not present, leading readers to believe the operation actually took 1 hour.

Jira issue: CRDB-14833

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants