Archive for October, 2009

Rails caching – resources

When you create anything serious on Ruby on Rails, you will most definitely need to start thinking about caching. As Ruby is a high-level language, a lot of crunching goes on to make the magic work. So in order for all this magic to work you should ensure that the heavy-lifting is done only once and after that you just use the results.

Good news is that caching in RoR is very powerful standard feature.

When should you start thinking about caching? It definitely pays off to know the proper ways to cache in RoR before you start coding anything serious. However, the optimization could be done at some later point, analyzing which queries, screens and views give you the most trouble.

Here’s how you should start with caching:

1 – View all the railscasts.com caching tutorials first. Although Ryan Bates does not go into details on the theory behind the caching, the ability to see a real-life example and get an easy explanation is priceless.

2 – After that read the “official” introduction to caching on the RoR site. You might want to skip some parts at the first reading.

3 – Finally, you should invest your time in the advanced video casts on Rails scaling by true experts NewRelic. These courses are made free for all to use – perfect!

Advertisements

October 31, 2009 at 2:02 pm Leave a comment


Recent posts

Starting to learn Rails?

Kindle

Get Kindle - the best e-book reader, that I personally use, and the only one that you can read on the beach - very useful: Kindle Wireless Reading Device (6" Display, Global Wireless, Latest Generation)