Rails architecture?

I would like to be able to read the Rails source code, but I think I canโ€™t do this because I donโ€™t know how to start and how the different parts of the code are connected. For example, it is obvious what ActiveModel does, and I can read the code, but I donโ€™t understand how the Rails application usually loads and when exactly the ActiveModel comes to the game, and what part of the rails calls it.

I'm not talking about this general material that people say in the manuals that the first Rack is loading, and Rails is a rack application ... No. I need something more detailed so that I can really look for every step in the code. Therefore, I suppose that some kind of diagram explaining how the rails application loads, and possibly a note for each of the subdir, saying where these files are used, what they do and where they really load on the boot diagram, would be nice.

Any tips on this?

+7
ruby-on-rails architecture
source share
2 answers

Rails follows the fairly traditional MVC (Model / View / Controller) design you can read.

If you want a good overview of how the request is handled by rails, this looks like a decent place to run:

http://betterexplained.com/articles/intermediate-rails-understanding-models-views-and-controllers/

Here's a more detailed article on how initializers and the Rails environment load:

http://toolmantim.com/thoughts/environments_and_the_rails_initialisation_process

The link is broken, here is the same article on github.

https://github.com/toolmantim/toolmantim/blob/master/articles/environments_and_the_rails_initialisation_process.haml

0
source share

It's not over yet, but this series of articles, Rails from Andrew Berls โ€™s answer request, helped me:

0
source share

All Articles