the basic process of ruby on rails
TRANSCRIPT
![Page 1: The basic process of Ruby on Rails](https://reader035.vdocument.in/reader035/viewer/2022071814/55a692191a28ab444d8b46a0/html5/thumbnails/1.jpg)
Ruby on Rails
Create powerful content management systems
![Page 2: The basic process of Ruby on Rails](https://reader035.vdocument.in/reader035/viewer/2022071814/55a692191a28ab444d8b46a0/html5/thumbnails/2.jpg)
Introduction
Ruby on Rails is a web application framework
Reasons to work with it: It is free There is a big community of developers It has a fast learning curve It is very very powerful It is flexible and can easily
accommodate to our needs
![Page 3: The basic process of Ruby on Rails](https://reader035.vdocument.in/reader035/viewer/2022071814/55a692191a28ab444d8b46a0/html5/thumbnails/3.jpg)
In this presentation we are going to zero in on the process. We want to understand what happens from the moment the user makes a request via URI to the response of the web server.
Work flow
![Page 4: The basic process of Ruby on Rails](https://reader035.vdocument.in/reader035/viewer/2022071814/55a692191a28ab444d8b46a0/html5/thumbnails/4.jpg)
URI
A user makes a request to a server via Internet through the protocol TCP/IP.
http://myapp.com/task/new
User Internet
ServerA DNS server in Internet identifies the server as the target of that domain
![Page 5: The basic process of Ruby on Rails](https://reader035.vdocument.in/reader035/viewer/2022071814/55a692191a28ab444d8b46a0/html5/thumbnails/5.jpg)
Routes
The route 'task/new' gets at the server. Rails identifies the route and directs it to the controller.
task/new Routes Controller task
![Page 6: The basic process of Ruby on Rails](https://reader035.vdocument.in/reader035/viewer/2022071814/55a692191a28ab444d8b46a0/html5/thumbnails/6.jpg)
Action
Once the controller has been identified, there are a number of actions that can take place. In our case we are looking for the action new
task/new Routes Controller task
Action show
![Page 7: The basic process of Ruby on Rails](https://reader035.vdocument.in/reader035/viewer/2022071814/55a692191a28ab444d8b46a0/html5/thumbnails/7.jpg)
Data base
The controller will gather the necessary data to be able to handle the request.
task/new Routes Controller task
Action show
Data base
Controller
Routes
![Page 8: The basic process of Ruby on Rails](https://reader035.vdocument.in/reader035/viewer/2022071814/55a692191a28ab444d8b46a0/html5/thumbnails/8.jpg)
Views
Now that the controller has collected the data it needs it will deliver it onto the view for rendering.
task/new Routes Controller task
Action show
Data base
Controller
Routes
RoutesView for the show action
![Page 9: The basic process of Ruby on Rails](https://reader035.vdocument.in/reader035/viewer/2022071814/55a692191a28ab444d8b46a0/html5/thumbnails/9.jpg)
Return to the user
Finally the web server delivers to the user the html generated by the view.
task/new Routes Controller task
Action show
Data base
Controller
Routes
RoutesView for the show actionInternet
![Page 10: The basic process of Ruby on Rails](https://reader035.vdocument.in/reader035/viewer/2022071814/55a692191a28ab444d8b46a0/html5/thumbnails/10.jpg)
Thanks. I hope it was helpful.
Feel free to improve it and share it.
Alberto Lamana