strawberry-graphql / strawberry

A GraphQL library for Python that leverages type annotations 🍓
https://strawberry.rocks
MIT License
3.96k stars 527 forks source link

Support for SSE in Subscriptions #2091

Open csuriano23 opened 2 years ago

csuriano23 commented 2 years ago

Is there a way to implement subscriptions as SSE instead of WebSockets or do you plan to add some support in the near future?

Upvote & Fund

Fund with Polar

patrick91 commented 2 years ago

we don't have support for SSE just yet, but I'd love to have it :)

elitepc commented 1 year ago

Hey, just checking in if someone has found an easy way to achieve this already.

patrick91 commented 1 year ago

@elitepc not yet, this would need us to implement the SSE protocol, and we haven't started working on in it just yet

devennavani commented 9 months ago

Wanted to +1 interest in this. A lot of folks are using websockets as the transport protocol for GraphQL subscriptions that stream chat responses (like from OpenAI's chat API) to their UIs, when really SSE should be sufficient :)

patrick91 commented 9 months ago

@devennavani I've been working on implementing multipart subscriptions, would that work for you?

omarzouk commented 7 months ago

Wanted to +1 interest in this as well. We would really like to take advantage of SSE since its simpler and more lightweight for our usecases

patrick91 commented 7 months ago

@omarzouk hopefully that's easy once I land #3076 :D