Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

How did it work before with RoR? The whole response was buffered and then sent at once with a Content-Length header?

I wonder why "HTTP Streaming" (known since years as "Chunked Encoding") is such a big deal now.



I don't think they're doing chunked encoding. I think they're making their template engine emit a stream instead of emitting the rendered page. Then, each time the template system has some text to send, it's written to the network rather than accumulated in a buffer that's all written at once.

The innovation is not what headers to send, it's to produce your data incrementally instead of all at once.


What I meant to write was that I don't think the encoding is what matters; incremental writes to tcp sockets are easy, and http is not much harder. What's hard is making your application code work well with this.


Not sure, but I know for myself it's because of node.js and a need for a better realtime app. I couldn't have told you what Chunked Encoding was before a couple weeks ago when I started fooling with node.js. Realtime apps are more popular, so node.js is more popular, so now people know about Chunked Encoding and Keep-Alives?




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: