<div dir="ltr">If the data is generated during the requests and there is no way to precompute it, I guess you best bet would be to generate and feed the data from a filter handler. Basically, the content handler for a particular location could be a the empty_gif module, and while the response is sent to the client you ignore the data generated by empty_gif, but instead send your stream data to the client. And when all the generated data is sent to the client, mark the empty_gif buffers as read.<div>empty_gif can be replaced with static file serving or anything really.<br><div>I'm not sure this would work at all, and how you will deal with the headers, but looking forward to see your progress.</div></div><div><br></div><div>Also, why not consider generating this data in a separate daemon and just using proxy_module or something.</div></div><div class="gmail_extra"><br><div class="gmail_quote">2015-11-09 20:35 GMT+02:00 Maksim Yevmenkin <span dir="ltr"><<a href="mailto:maksim.yevmenkin@gmail.com" target="_blank">maksim.yevmenkin@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">hello,<br>
<br>
suppose i need to export large amount of nginx generated data (static<br>
page). i have used content handler (or content phase handler) to<br>
create all the in-memory chain and fed it to ngx_http_output_filter().<br>
however, i would very much like to avoid allocating large chunk of<br>
memory to keep all the data before sending.<br>
<br>
is there a way to stream generated page (potentially applying<br>
different transfer encoding)?<br>
<br>
thanks!<br>
max<br>
<br>
_______________________________________________<br>
nginx-devel mailing list<br>
<a href="mailto:nginx-devel@nginx.org">nginx-devel@nginx.org</a><br>
<a href="http://mailman.nginx.org/mailman/listinfo/nginx-devel" rel="noreferrer" target="_blank">http://mailman.nginx.org/mailman/listinfo/nginx-devel</a><br>
</blockquote></div><br></div>