-
Notifications
You must be signed in to change notification settings - Fork 654
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
grpc-js: Apply timeouts from service configs #1785
grpc-js: Apply timeouts from service configs #1785
Conversation
Hi 👋 Is this going to be added to grpc-js 1.3.x ? I see it got merged in May but isn't in 1.3.7 (latest release). If not, what's the ETA for 1.4.x? In the meantime, would you consider showing some warnings when validating Thanks! |
This is part of 1.4. We currently don't intend to backport it to 1.3. 1.4 will be released as soon as possible, whenever that ends up being. The focus of the current service config validation code is validating it according to the spec, so that we don't incorrectly reject service configs retrieved over the network. But I can look into adding some logs there. Regarding the package comparison doc, "deadlines" there refers to providing deadlines when making requests, not to configuring timeouts in service configs. You may be right that other users have faced similar problems, but nobody has ever filed an issue or otherwise contacted us about that, so I wouldn't know about it. In fact, the goal of this PR wasn't even to support this use case, it was to support using timeouts with service configs retrieved from an xDS server. |
Thanks @murgatroid99 , appreciate the fast answer! |
Some comments from my team regarding the usage you described:
|
This is the grpc-js side of the timeout part of proposal A31: the mechanism for applying a timeout from a service config to each individual request. The xDS side uses xDS v3-specific fields, so I will do that after #1765 is merged.
I changed the method config definition to more closely match the spec. The validation code still accepts the same inputs it accepted before, so that shouldn't break anything.
This puts the deadline filter in a weird state. It already had some implicit coupling with the deadline exposed by the call stream class, but now that deadline can change and the filter needs to take action when that happens. I don't really know what to do about that, so I'm deferring that to another time.