gateway-api
gateway-api copied to clipboard
Support Request Timeouts for GRPCRoute
What would you like to be added:
A request.Timeout field within GRPCRoute similar to the one added in HTTPRoute as part of https://gateway-api.sigs.k8s.io/geps/gep-1742/
Why this is needed:
- Set a request timeout for unary rpc, that may vary from the default timeout of the implementation
- Disable timeouts (set to
0s) for streaming rpc
cc @robscott @frankbu @gnossen
Good call @arkodg! I think this one should be relatively straightforward, but because it's a new API field in a GA resource, we'll likely need to track it with a separate GEP. Do you mind adding this to https://github.com/kubernetes-sigs/gateway-api/discussions/3103 if you think you'd have time to lead this in v1.2?
sure @robscott done
The Kubernetes project currently lacks enough contributors to adequately respond to all issues.
This bot triages un-triaged issues according to the following rules:
- After 90d of inactivity,
lifecycle/staleis applied - After 30d of inactivity since
lifecycle/stalewas applied,lifecycle/rottenis applied - After 30d of inactivity since
lifecycle/rottenwas applied, the issue is closed
You can:
- Mark this issue as fresh with
/remove-lifecycle stale - Close this issue with
/close - Offer to help out with Issue Triage
Please send feedback to sig-contributor-experience at kubernetes/community.
/lifecycle stale
This is still in progress, and may be in scope for 1.3.
/remove-lifecycle stale
What does the roadmap look like for this item, seems like it was removed from the plan for 1.3?
Not having this makes 'this implementation supports GRPCRoutes' type proclamations misleading, since the actual behavior on timeouts can make long gRPC streams completely unusable. Implementations can offer various workarounds but in the end IMO this should just be a part of the CRD since the functionality is so commonly needed with GRPC too.
what status about this issue?
For others who come across this issue, I was able to work around the lack of this for now when using Envoy gateway by using a BackendTrafficPolicy
---
apiVersion: gateway.envoyproxy.io/v1alpha1
kind: BackendTrafficPolicy
metadata:
name: mgmt-timeouts
spec:
targetRefs:
- group: 'gateway.networking.k8s.io'
kind: GRPCRoute
name: mgmt
timeout:
http:
requestTimeout: 0s
connectionIdleTimeout: 3600s
tcpKeepalive:
idleTime: 30s
interval: 30s
probes: 5