Introduzione a Ruby On Rails
- 1. Lo sviluppo agile di
applicazioni web
(su database Oracle)
Conferenza Annuale OUGIT
Parma – 1 dicembre 2006
Luca Mearelli
- 8. Predire il futuro è per gli oracoli
Distillato da un servizio reale
È l'unico modo di creare un framework
Occorre provare le API sul campo
- 9. Principi
Less Is More
Don't Repeat Yourself
Convention Over Configuration
Constraints Are Liberating
Flexibility Is Overrated
- 10. Ruby !?!
Tutto è un oggetto
Espressività dei blocchi
Introspezione
Estensione a runtime
Librerie ricche
- 12. Un ambiente per la creazione di applicazioni
web
Una soluzione completa per un problema
Focalizzata sugli obiettivi non sui mezzi
Non una singola grossa innovazione
Infrastruttura NON Business Logic
- 13. Integrato
Dalle pagine al database
un linguaggio solo per tutti i livelli
si prende cura dei piccoli particolari
- 16. ActiveRecord
ORM che implementa il pattern ActiveRecord
ActionPack
Controllo del flusso e gestione delle viste (il VC nel MVC).
ActionMailer
Gestione delle email (invio, ricezione, test)
ActionWebService
Supporto per i Web service.
ActiveSupport
Utility di supporto del framework.
Plugins
- 19. utente = User.new
utente.name = “Scott Tiger”
utente.save
User.create( { :login=>’luca’,
:name=>’Luca Mearelli’
})
lm = User.find_by_login(‘luca’)
lm.name #‘Luca Mearelli’
- 44. Il risultato
quot;Most web frameworks force the developer to focus on the needs of the
framework. You spend your time configuring X, or interfacing between
Y and Z. Rails isn't like that. With Rails you focus on delivering value
to your users. Everything else just gets taken care of. Rails finally
brings agility to the web.quot;
Dave Thomas
quot;Rails has become a standard to which even well-established tools are
comparing themselves to.quot;
Martin Fowler, Autore di Refactoring, PoEAA, XP Explained
quot;Ruby on Rails is a breakthrough in lowering the barriers of entry to
programming. Powerful web applications that formerly might have taken
weeks or months to develop can be produced in a matter of days.quot;
Tim O'Reilly, Fondatore di O'Reilly Media
quot;Rails is the most well thought-out web development framework I've ever
used. And that's in a decade of doing web applications for a living.
I've built my own frameworks, helped develop the Servlet API, and have
created more than a few web servers from scratch. Nobody has done it
like this before.“