What code runs when you request a page from a Ruby on Rails application?
Here is an annotated trace showing every method call within Rails and its dependencies. It is for an example application that loads a blog post from the database and renders a page containing the post's title.
This is the first point in dealing with the request that we run our application code.
The request we've made is to show a single blog post. The
set_post method loads the record from the database. It's defined as a
before_action so it runs before the controller action and the view.