<div dir="ltr">Hi,<div><br></div><div>I'm not sure if it would fit in the pageonex workflow, but a common pattern is to place outside the web application slow or cpu consuming tasks, as resizing images. A queue could be used for that. It can be placed in the same server or if you need to scale out, it can be placed in another server.</div>
<div><br></div><div>This two queues have a ruby client:</div><div><br></div><div><a href="http://kr.github.io/beanstalkd/">http://kr.github.io/beanstalkd/</a><br></div><div><a href="https://github.com/resque/resque">https://github.com/resque/resque</a><br>
</div><div><br></div><div>I've used beanstalkd and it works perfectly fine and it is very easy to setup. I haven't used resque, but I know people that have used it and it works pretty well for them.</div><div><br>
</div><div>Best regards,</div><div><br></div><div>Rafa</div><div><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">2013/12/10 pablo rey <span dir="ltr"><<a href="mailto:pablo@basurama.org" target="_blank">pablo@basurama.org</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div><div>Great, Ed, how is this CPU throttling working?<br><br>I added one extra day to the thread <a href="http://pageonex.com/numeroteca/corrupcion-espana-diciembre-2013/" target="_blank">http://pageonex.com/numeroteca/corrupcion-espana-diciembre-2013/</a> and updated:<br>
<br>1st time: internal server error.<br><br></div><div>I reloaded:<br></div>2nd time: the newspaper images and overlays were broken.<br><br>I went back to edit and "updated" the thread<br></div>3rd time: it worked fine.<br>
<br><br></div></div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Dec 9, 2013 at 11:12 PM, Edward Platt <span dir="ltr"><<a href="mailto:elplatt@media.mit.edu" target="_blank">elplatt@media.mit.edu</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">I've added cpu throttling to the imagemagick settings. Hopefully this will help stop the crashes, but keep an eye out for any weird behavior!<div>
<br></div><div>-Ed</div></div><div><div><div class="gmail_extra"><br>
<br><div class="gmail_quote">On Sun, Dec 8, 2013 at 12:14 PM, pablo rey <span dir="ltr"><<a href="mailto:pablo@basurama.org" target="_blank">pablo@basurama.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr"><div><div><div><div>Hi Ed,<br></div>Prevent overloading would be great. <br>I think the server just went down again when editing the same thread.<br><br></div>Let's talk next week if there is something I can look into also.<span><font color="#888888"><br>
</font></span></div></div><span><font color="#888888">p</font></span><div><div><br><div><div><div><div><div><div><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, Dec 6, 2013 at 11:19 PM, Edward Platt <span dir="ltr"><<a href="mailto:elplatt@media.mit.edu" target="_blank">elplatt@media.mit.edu</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hey Pablo!<div><br></div><div>The server's back up. We've been getting notifications about cpu and disk usage, probably from resizing images. Next week I'll look into whether there's an easy fix to prevent overloading the server on long/short threads.</div>
<div><br></div><div>-Ed</div></div><div class="gmail_extra"><br><br><div class="gmail_quote"><div><div>On Fri, Dec 6, 2013 at 5:30 AM, pablo rey <span dir="ltr"><<a href="mailto:pablo@basurama.org" target="_blank">pablo@basurama.org</a>></span> wrote:<br>
</div></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div><div><div dir="ltr"><div><div>Hi Ed and Rahul,<br>I was adding a new topic to the thread <a href="http://pageonex.com/numeroteca/corrupcion-espana-diciembre-2013/" target="_blank">http://pageonex.com/numeroteca/corrupcion-espana-diciembre-2013/</a> and the server went down.<br>
<br></div>I can not ssh.<br><br></div><div>Apart from the problem of lack of memory to calculate the background image grid for too many or too few images, I think there is another problem with too many overlays when it has to create the composites.<br>
</div><div><br></div>Please reboot over-9000 server!<br></div>
<br></div></div>_______________________________________________<br>
Pageonexdev mailing list<br>
<a href="mailto:Pageonexdev@mit.edu" target="_blank">Pageonexdev@mit.edu</a><br>
<a href="http://mailman.mit.edu/mailman/listinfo/pageonexdev" target="_blank">http://mailman.mit.edu/mailman/listinfo/pageonexdev</a><br>
<br></blockquote></div><span><font color="#888888"><br><br clear="all"><div><br></div>-- <br><div dir="ltr"><div>Edward L. Platt<br></div><div>Civic Technology Programmer</div><div>MIT Center for Civic Media</div>
<div>E15-348</div><div><a href="http://civic.mit.edu" target="_blank">http://civic.mit.edu</a></div>
<div><a href="http://elplatt.com" target="_blank">http://elplatt.com</a></div><div><a href="http://twitter.com/elplatt" target="_blank">@elplatt</a></div></div>
</font></span></div>
<br>_______________________________________________<br>
Pageonexdev mailing list<br>
<a href="mailto:Pageonexdev@mit.edu" target="_blank">Pageonexdev@mit.edu</a><br>
<a href="http://mailman.mit.edu/mailman/listinfo/pageonexdev" target="_blank">http://mailman.mit.edu/mailman/listinfo/pageonexdev</a><br>
<br></blockquote></div><br></div></div></div></div></div></div></div></div></div></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div dir="ltr"><div>Edward L. Platt<br></div><div>Civic Technology Programmer</div><div>MIT Center for Civic Media</div><div>E15-348</div><div><a href="http://civic.mit.edu" target="_blank">http://civic.mit.edu</a></div>
<div><a href="http://elplatt.com" target="_blank">http://elplatt.com</a></div><div><a href="http://twitter.com/elplatt" target="_blank">@elplatt</a></div></div>
</div>
</div></div></blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
Pageonexdev mailing list<br>
<a href="mailto:Pageonexdev@mit.edu">Pageonexdev@mit.edu</a><br>
<a href="http://mailman.mit.edu/mailman/listinfo/pageonexdev" target="_blank">http://mailman.mit.edu/mailman/listinfo/pageonexdev</a><br>
<br></blockquote></div><br></div>