[Rails] Re: Suggestions for my first serious Ruby on Rails project
I would do just like I've done for automated tasks in several other Rails apps I've written: make a rake task for it which can be triggered via cron job. The rake task can simply trigger a model method to do whatever needs done. This keeps all code relevant to the app in the application (and more specifically, all code relevant to that model actually in the model), allows you to use ActiveRecord instead of interacting directly with the database via sql, and gives you easy access to any other functionality you build into your app. It also gives you the ability to more easily allow a user to trigger a partial update via the web site should that functionality ever be desired.
On Saturday, February 16, 2013 7:48:21 PM UTC-5, Jason Hsu, Android developer wrote:
Given all this, if my web site dedicated to finding the most undervalued ETFs and mutual funds were your project instead of mine, how would you go about it?
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-talk/-/uXrX5azTivcJ.
For more options, visit https://groups.google.com/groups/opt_out.
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home