Skip to content

Does spin/fermyon cloud support SSE? #1867

Answered by itowlson
maxwell8888 asked this question in Q&A
Discussion options

You must be logged in to vote

It isn't possible in Spin 1.x, but it should be possible in Spin 2.x and the corresponding iteration of Fermyon Cloud. The reason is that in Spin 1.x you have to return the entire HTTP response at once, whereas in Spin 2.x you should be able to stream it. You'll then be able to use the server-side events protocol (https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#sending_events_from_the_server) to emit events as required.

@dicej is working on streaming responses and can hopefully confirm or deny.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@dicej
Comment options

Answer selected by maxwell8888
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants