max
Deno.serve: Is it possible to flush a streaming response?
I've been playing around with this: https://docs.deno.com/examples/http-server-streaming
I am coming from Go and I'm used to having the functionality to flush the http response to the socket. Allowing lots of control over when bytes are sent over the wire (like so: https://robpike.io/)
Is there any mechanism to prompt deno to write to the socket? Maybe another streaming response type?
Thanks!
5 replies
With Deno.serveHttp marked as deprecated is there a way to run an HTTP server off of a Deno.Conn?
I have a bit of weird use-case where I want to start a listener, accept the first TCP connection (and serve HTTP to it) and then reject all future TCP connections.
I have the following code:
Is there a way to do this using Deno.serve, or something else?
8 replies