sonora icon indicating copy to clipboard operation
sonora copied to clipboard

Regular gRPC support

Open public opened this issue 5 years ago • 3 comments
trafficstars

Currently everything is built assuming gRPC-Web but it doesn't seem like it would be much work to also support normal gRPC with H2 only connections although it would depend on there being a WSGI or ASGI server that could actually speak that.

  • [ ] Is it feasible that any existing ASGI or WSGI servers could speak gRPC? This mostly means supporting bare H2 connections.
  • [ ] What does sonora need to do to support regular gRPC?

public avatar Feb 21 '20 16:02 public

As I understand it, the main problem is that the HTTP/2 gRPC protocol requires sending errors as HTTP trailers. Trailers aren't specific to HTTP/2, but as far as I know they're not exposed by the WSGI standard. (I don't know about ASGI.)

Is there typically an implementation-specific way to access HTTP features that aren't part of the standard?

akshayjshah avatar Jan 19 '22 16:01 akshayjshah

Re WSGI https://github.com/python-web-sig/wsgi-ng/issues/9 it's not clear if any implementations support it even via an environ extension.

Re ASGI https://github.com/django/asgiref/issues/141 I think there is some interest in providing this capability but seems like no implementations support it yet either.

public avatar Jan 19 '22 18:01 public

Re ASGI django/asgiref#141 I think there is some interest in providing this capability but seems like no implementations support it yet either.

HTTP Trailers was added to the ASGI spec: https://github.com/django/asgiref/pull/339

jluebbe avatar Jul 01 '24 09:07 jluebbe