<div dir="ltr">Hey Riccardo,<br><div class="gmail_extra"><br><div class="gmail_quote">On Mon, May 30, 2016 at 9:47 AM, Riccardo Magliocchetti <span dir="ltr"><<a href="mailto:riccardo.magliocchetti@gmail.com" target="_blank">riccardo.magliocchetti@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">Il 30/05/2016 02:50, Markus Mohrhard ha scritto:<br>
</span><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">
Hey Riccardo,<br>
<br>
On Sun, May 29, 2016 at 4:38 PM, Riccardo Magliocchetti<br></span><span class="">
<<a href="mailto:riccardo.magliocchetti@gmail.com" target="_blank">riccardo.magliocchetti@gmail.com</a> <mailto:<a href="mailto:riccardo.magliocchetti@gmail.com" target="_blank">riccardo.magliocchetti@gmail.com</a>>> wrote:<br>
<br>
    Hello Markus,<br>
<br>
    Il 29/05/2016 13:11, Markus Mohrhard ha scritto:<br>
<br>
        ** Server (code at <a href="https://github.com/mmohrhard/crash" rel="noreferrer" target="_blank">https://github.com/mmohrhard/crash</a> )<br>
<br>
        automated a few workflows (currently the processing is async and needs to be<br>
        done manually)<br>
<br>
<br>
    Do you have more details for this item?<br>
<br>
<br>
Everything in the processor/views.py is part of these tasks. The ones that<br>
currently come to my mind are transformation from uploaded to processed crash<br>
and generation of the crash count numbers for the main page. For each of them we<br>
need a python script that calls them and add the script with a cron job.<br>
Another task that might need similar handling but is not implemented at all yet<br>
is to delete symbols of old releases.<br>
<br>
Does that make sense to you?<br>
</span></blockquote>
<br>
Yep, since you are using uwsgi (and if you are willing to use it also in development) you can leverage its spooler or cron functionalities [1] to handle these tasks. Or they can be implemented as django management commands so you don't need another script to call them via http.<br>
<br>
[1] <a href="http://uwsgi-docs.readthedocs.io/en/latest/PythonDecorators.html" rel="noreferrer" target="_blank">http://uwsgi-docs.readthedocs.io/en/latest/PythonDecorators.html</a></blockquote><div><br><br></div><div>What would be the advantage to writing a python management script that works through http? My plan was to write a python management script and add it as a cron job (about one minute for the processing of uploaded crashes and once a day for the crash count).<br><br></div><div>The advantage that I currently see for an independent script is that I can call it from wherever I am. Not only if I'm logged-in. What would be the benefit of the other solutions?<br><br></div><div>Regards<br></div><div>Markus<br> <br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5"><br>
<br>
-- <br>
Riccardo Magliocchetti<br>
@rmistaken<br>
<br>
<a href="http://menodizero.it" rel="noreferrer" target="_blank">http://menodizero.it</a><br>
</div></div></blockquote></div><br></div></div>