Hello,<div><br>&nbsp;</div><div>I am trying to build an application that will parse thousands of XML Feeds in continue in the back.</div><div>I really have no idea on how to do this &quot;correctly&quot; with Rails.</div><div><br>
&nbsp;</div><div>Here is my code :</div><div><br>&nbsp;</div><div><div>class Feed &lt; ActiveRecord::Base</div><div>&nbsp;&nbsp;def parse</div><div><span class="Apple-tab-span" style="white-space:pre">        </span>&nbsp;&nbsp;# Parsing using external lib (syndication gem)<br>
&nbsp;</div><div>&nbsp;&nbsp;end</div><div>end</div><div><br>&nbsp;</div><div><div>class FeedsController &lt; ApplicationController</div><div>&nbsp;&nbsp;def parse</div><div>&nbsp;&nbsp; &nbsp;feed = Feed.find(params[:id])</div><div>&nbsp;&nbsp; &nbsp;feed.parse</div><div>&nbsp;&nbsp;end</div>
<div>end</div></div></div><div><br>&nbsp;</div><div>So for now, if I want to parse all my feeds forever, what I have to do is to call <a href="http://myapp/feeds/1/parse">http://myapp/feeds/1/parse</a>, and then&nbsp;<a href="http://myapp/feeds/2/parse">http://myapp/feeds/2/parse</a> ...</div>
<div>This is definetely not a good solution!</div><div><br>&nbsp;</div><div>How can I use&nbsp;<span class="Apple-style-span" style="white-space: pre; ">Backgroundrb to do this?</span></div><div><span class="Apple-style-span" style="white-space: pre;"><br>
</span></div><div><span class="Apple-style-span" style="white-space: pre;">Thanks for your help!</span></div><div><br>&nbsp;</div><div>--<br>Julien Genestoux<br><a href="mailto:julien.genestoux@gmail.com">julien.genestoux@gmail.com</a><br>
+1 (415) 254 7340<br>+33 (0)8 70 44 76 29
</div>