Re: StreamingHttpResponse into a Template

2013-02-28 Thread Sam Solomon
Not sure if this is what you meant by "we'll probably keep the javascript reloading to process junks, waiting for the support of celery", but one option without celery is to have the initial request save a bunch of "PendingEmail" objects in the database and then redirect you to a "send_queued_e

Re: StreamingHttpResponse into a Template

2013-02-28 Thread Stefano Tranquillini
Yes, you are perfectly right about the fact that this is a bad implementation. the fact is that where i host the code it does not support celery (so far). so i've to find out a workaround to be able to process a bunch of external APIs Call (that include the one for sending email). we'll probabl

Re: StreamingHttpResponse into a Template

2013-02-27 Thread Masklinn
On 2013-02-27, at 18:47 , Stefano Tranquillini wrote: > Hi, thank you for the answer. > basically what i've to do is to iterate the same operation for a bunch of > user (e.g. send an email). > i've around 200 users and each mail takes 2 seconds. > so 400 seconds in total and the server goes in tim

Re: StreamingHttpResponse into a Template

2013-02-27 Thread Masklinn
On 2013-02-27, at 18:23 , Stefano Tranquillini wrote: > Django 1.5 is just came out and it ships the StreamingHttpResponse. > > What i want to do is to print the output of a stream response into a > template I'm pretty sure that doesn't make sense: the template has to be rendered, and I'm prett

StreamingHttpResponse into a Template

2013-02-27 Thread Stefano Tranquillini
Django 1.5 is just came out and it ships the StreamingHttpResponse. What i want to do is to print the output of a stream response into a template, having for example a bar that grows based on the streamed data (something similar to a loading bar). so far i've found a solution that basically