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

Set grpc-timeout in milliseconds #89

Merged
merged 1 commit into from
Sep 27, 2022

Conversation

psalin
Copy link
Collaborator

@psalin psalin commented Sep 14, 2022

Setting it in nanoseconds overflowed the maximum length (8) of the header already at 100ms, causing PROTOCOL_ERROR responses. Using ms instead of ns is not bullet proof either, but covers the range of 1ms - ~27h. Seems most if not all use cases should fit in this range and doing extra calculations for covering more range might not be worth it performance-wise.

Fixes #85

Setting it in nanoseconds overflowed the maximum length (8) of the
header already at 100ms, causing PROTOCOL_ERROR responses. Using
ms instead of nanoseconds is not bullet proof either, but covers
the range of 1ms - ~27h.
@codecov
Copy link

codecov bot commented Sep 14, 2022

Codecov Report

Base: 39.02% // Head: 39.05% // Increases project coverage by +0.02% 🎉

Coverage data is based on head (8825884) compared to base (8cad52b).
Patch coverage: 100.00% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #89      +/-   ##
==========================================
+ Coverage   39.02%   39.05%   +0.02%     
==========================================
  Files          28       28              
  Lines        2091     2092       +1     
==========================================
+ Hits          816      817       +1     
  Misses       1275     1275              
Impacted Files Coverage Δ
src/grpcbox_client_stream.erl 69.33% <100.00%> (+0.41%) ⬆️
src/grpcbox_stream.erl 64.61% <0.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@tsloughter tsloughter merged commit 8259a65 into tsloughter:main Sep 27, 2022
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 this pull request may close these issues.

grpc-timeout header not matching the spec
2 participants