SlideShare a Scribd company logo
1 of 210
Download to read offline
Защо Ruby on Rails?

          Стефан Кънев
         http://skanev.com/



          25 април 2009 г.
          Велико Търново
Живот
 без
болка
Помагам за болки в
кръста, но не и болки в уеб
     програмирането.




          Д-р Ливайн
Ruby on Rails
     • Web framework
     • Лекува болки всякакви
     • Препоръчва се от
       националната лекарска
       асоциация
     • Съдържа коензим Q  10

     • Преди употреба
       протечете листовката!
↓Код ☹
↑Опит☺
На практика
Can I has Rails?
Как? Защо?
???
???
http://twitter.com/skanev




         ???
http://twitter.com/skanev
@skanev А дали Rails лекува проблеми с
простатата?




         ???
http://twitter.com/skanev
@skanev А дали Rails лекува проблеми с
простатата?

✌ Ам, таковата, да питам аз...



         ???
Ruby on Rails
Ruby on Rails
         web framework
Ruby on Rails
          web framework

       2005
Ruby on Rails
          web framework

       2005




       DHH
Ruby on Rails
                          web framework
език за програмиране
                       2005




                       DHH
Ruby on Rails
                         web framework
език за програмиране
                1995 2005




                       DHH
Ruby on Rails
                        web framework
език за програмиране
                1995 2005




                Matz DHH
1. Моя сблъсък с Rails
1. Моя сблъсък с Rails
2. Rails накратко
1. Моя сблъсък с Rails
2. Rails накратко
3. Ruby накратко
1. Моя сблъсък с Rails
2. Rails накратко
3. Ruby накратко
4. Култура и общество
1. Моя сблъсък с Rails
2. Rails накратко
3. Ruby накратко
4. Култура и общество
5. Rails в живия живот
1. Моя сблъсък с Rails
2. Rails накратко
3. Ruby накратко
4. Култура и общество
5. Rails в живия живот
6. Това за мен ли е?
1. Моя сблъсък с Rails
2. Rails накратко
3. Ruby накратко
4. Култура и общество
5. Rails в живия живот
6. Това за мен ли е?
7. Как да се запозная с Rails?
vs.
Round 1
пролет 2006
УНСС
WTF
database fixtures
database fixtures
    jpaUnit
декември 2006
PHP
cakePHP
cakePHP
vanilla PHP
2 седмици
събота, обяд
30 часа
понеделник сутрин
вторник вечер
2 седмици
     ↓
  2 дена
Rails - 5 пъти
по-бързо от PHP
✕
  Rails - 5 пъти
по-бързо от PHP

      Не!
Първи впечатления
Първи впечатления

1. Добра идея за не-Rails проект
Първи впечатления

 1. Добра идея за не-Rails проект

2. Лесен за учене, свърши ми работа
1. Моят сблъсък с Rails
2. Rails накратко
3. Ruby накратко
4. Култура и общество
5. Rails в живия живот
6. Това за мен ли е?
7. Как да се запозная с Rails?
MVC
MVC
MVC
ActiveRecord
MVC
ActiveRecord
       ActionView
MVC
ActiveRecord
       ActionView
               ActionPack
версии на БД схемата
версии на БД схемата
    яко тестване
версии на БД схемата
    яко тестване
   много плъгини
Твърде много
 абстракция
✕
Твърде много
 абстракция
       Ни!
   (така де, Не!)
HTTP

SQL          HTML
Rails is about less code.
        - David Heinemeier Hansson
D.R.Y.
D.R.Y.
Don’t Repeat Yourself
C.O.C.
C.O.C.
Convention Over Configuration
1. Моят сблъсък с Rails
2. Rails накратко
3. Ruby накратко
4. Култура и общество
5. Rails в живия живот
6. Това за мен ли е?
7. Как да се запозная с Rails?
прагматичност > чистота
duck typing
  ала Perl и Python
                                интерпретира се
general purpose
                               динамичен
            обектно-ориентиран



     вдъхновен от Perl, Smalltalk, CLU и Lisp
duck typing
  ала Perl и Python
                                интерпретира се
general purpose
                               динамичен
            обектно-ориентиран



     вдъхновен от Perl, Smalltalk, CLU и Lisp
duck typing
  ала Perl и Python
                                интерпретира се
general purpose
                               динамичен
            обектно-ориентиран



     вдъхновен от Perl, Smalltalk, CLU и Lisp
duck typing
  ала Perl и Python
                                интерпретира се
general purpose
                               динамичен
            обектно-ориентиран



     вдъхновен от Perl, Smalltalk, CLU и Lisp
duck typing
  ала Perl и Python
                                интерпретира се
general purpose
                               динамичен
            обектно-ориентиран



     вдъхновен от Perl, Smalltalk, CLU и Lisp
duck typing
  ала Perl и Python
                                интерпретира се
general purpose
                               динамичен
            обектно-ориентиран



     вдъхновен от Perl, Smalltalk, CLU и Lisp
duck typing
  ала Perl и Python
                                интерпретира се
general purpose
                               динамичен
            обектно-ориентиран



     вдъхновен от Perl, Smalltalk, CLU и Lisp
duck typing
  ала Perl и Python
                                интерпретира се
general purpose
                               динамичен
            обектно-ориентиран



     вдъхновен от Perl, Smalltalk, CLU и Lisp
Treating Code As An Essay
      - Yukihiro Matsumoto
Ruby.is_not? :mainstream
Meta-programming
Programming Bottom-Up
http://www.paulgraham.com/progbot.html
Programming Bottom-Up
http://www.paulgraham.com/progbot.html

              ViaWeb
Programming Bottom-Up
http://www.paulgraham.com/progbot.html

             ViaWeb
           Yahoo! Store
1. Моят сблъсък с Rails
2. Rails накратко
3. Ruby накратко
4. Култура и общество
5. Rails в живия живот
6. Това за мен ли е?
7. Как да се запозная с Rails?
The Ruby Way
The Rails Way
иновативен
unit tests
RSpec
Behavior
Driven
Development
BDD = ++TDD
практичен
+
+
+   +
Programming
+   +
       Bottom-Up
Programming
+       +
           Bottom-Up
    =
Programming
+       +
           Bottom-Up
    =
Programming
+       +
           Bottom-Up
    =

        +
Programming
+       +
           Bottom-Up
    =

        +
бързи темпове
3rd edition
1.2




      3rd edition
1.2

      start → 2.0




             3rd edition
1.2                 2.0

      start → 2.0




             3rd edition
1.2                 2.0    2.2

      start → 2.0




             3rd edition
1.2                 2.0    2.2

      start → 2.0                update




             3rd edition
1.2                 2.0    2.2

      start → 2.0                update   in print




             3rd edition
1.2                 2.0    2.2                       2.3

      start → 2.0                update   in print




             3rd edition
Ruby.is_not? :mainstream
Elitist
1. Моят сблъсък с Rails
2. Rails накратко
3. Ruby накратко
4. Култура и общество
5. Rails в живия живот
6. Това за мен ли е?
7. Как да се запозная с Rails?
Ruby.kind_of? Mature
~ 100 книги
rubyonrails-talk @ google-groups ~ 18 000 човека
rubyonrails-talk @ google-groups ~ 18 000 човека

  #rubyonrails @ freenode ~ 500 човека 24/7
rubyonrails-talk @ google-groups ~ 18 000 човека

  #rubyonrails @ freenode ~ 500 човека 24/7

          1000+ разширения (plugins)
rubyonrails-talk @ google-groups ~ 18 000 човека

  #rubyonrails @ freenode ~ 500 човека 24/7

          1000+ разширения (plugins)

             много, много блогове
Yes
       Ja

 Да
Oui
Rails.users
43things.com
getsatisfaction.com
scribd.com
geni.com
Ruby.vm
JRuby
IronRuby
Rubinus
Scalability
6 часа
10 000 - 100 000
100 000+
Deploy
Mongrel
Mongrel

Mongrel,Mongrel,Mongrel
Mongrel

Mongrel,Mongrel,Mongrel

        Apache
Phusion Passanger
Phusion Passanger
    mod_rails
nginx
Hosting
1. Моят сблъсък с Rails
2. Rails накратко
3. Ruby накратко
4. Култура и общество
5. Rails в живия живот
6. Това за мен ли е?
7. Как да се запозная с Rails?
Can I has Rails?
Какво съм аз?
Какво съм аз?



програмист
Какво съм аз?



програмист    мениджър
Какво съм аз?



програмист    мениджър
Какво съм аз?



програмист        мениджър
             собственик на бизнес
Какво съм аз?



програмист        мениджър
             собственик на бизнес
време и енергия
време и енергия
 ангажираност
време и енергия
  ангажираност
the rails/ruby way
време и енергия
  ангажираност
the rails/ruby way
   експертиза
време и енергия
  ангажираност
the rails/ruby way
   експертиза
 бързи темпове
малки екипи
добри програмисти
agile
scrum
extreme programming
по-бързо
по-бързо
по-чисто
по-бързо
по-чисто
по-лесно
PHP - Safe
Other stuff - Risky
Анди
5 years PHP
$hndl = connect(“niklas@192.16.20.54”;
cd($hndl, “/home/niklas/prj2/”);
SELECT projekt, namn,
author FROM ...
Foreign Key
     =
Френски ключ
     ?
<?php if ($user->name == ‘meriksson’): ?>
...
<?php endif ?>
3 full days
50%
Анди
1. Моят сблъсък с Rails
2. Rails накратко
3. Ruby накратко
4. Култура и общество
5. Rails в живия живот
6. Това за мен ли е?
7. Как да се запозная с Rails?
http://railscasts.com
Blog in 15 minutes
http://rubyonrails.org/
The Rails activists
http://guides.rubyonrails.org/
http://poignantguide.net/
http://api.rubyonrails.org/
http://skanev.com/
139
Questions
     &
Discussions
        http://skanev.com/

More Related Content

Viewers also liked (9)

Debugging Habits
Debugging HabitsDebugging Habits
Debugging Habits
 
Informatiethema's: naar het buitenland
Informatiethema's: naar het buitenlandInformatiethema's: naar het buitenland
Informatiethema's: naar het buitenland
 
Nature of Chase
Nature of ChaseNature of Chase
Nature of Chase
 
Windows 7 Developer Overview
Windows 7 Developer OverviewWindows 7 Developer Overview
Windows 7 Developer Overview
 
5. HTTP и приятели
5. HTTP и приятели5. HTTP и приятели
5. HTTP и приятели
 
Doorlichting JIPS 2009
Doorlichting JIPS 2009Doorlichting JIPS 2009
Doorlichting JIPS 2009
 
Ecophon - Akusto - FR
Ecophon - Akusto - FREcophon - Akusto - FR
Ecophon - Akusto - FR
 
Silverlight 2
Silverlight 2Silverlight 2
Silverlight 2
 
Presentación estructura
Presentación estructuraPresentación estructura
Presentación estructura
 

Similar to Защо Ruby on Rails

P2 P Mobile Advertising And Targeting
P2 P Mobile Advertising And TargetingP2 P Mobile Advertising And Targeting
P2 P Mobile Advertising And Targeting
guest258f78a
 
Упаковка и развертывание программ на perl под debian‎
Упаковка и развертывание программ на perl под debian‎Упаковка и развертывание программ на perl под debian‎
Упаковка и развертывание программ на perl под debian‎
mayperl
 
тупицын Ec2 Rootconf2009
тупицын Ec2 Rootconf2009тупицын Ec2 Rootconf2009
тупицын Ec2 Rootconf2009
Liudmila Li
 
11 Net Scaler Xa1
11 Net Scaler Xa111 Net Scaler Xa1
11 Net Scaler Xa1
Liudmila Li
 
введение в Ror олег андреев
введение в Ror   олег андрееввведение в Ror   олег андреев
введение в Ror олег андреев
Media Gorod
 
Intro To RDBMS And SQL Server 2005 - Svetlin Nakov
Intro To RDBMS And SQL Server 2005 - Svetlin NakovIntro To RDBMS And SQL Server 2005 - Svetlin Nakov
Intro To RDBMS And SQL Server 2005 - Svetlin Nakov
Svetlin Nakov
 
Minsk Jazz 190509 Templ
Minsk Jazz 190509 TemplMinsk Jazz 190509 Templ
Minsk Jazz 190509 Templ
sef2009
 
OO Design with C++: 1. Inheritance, part 1
OO Design with C++: 1. Inheritance, part 1OO Design with C++: 1. Inheritance, part 1
OO Design with C++: 1. Inheritance, part 1
Dmitry Stillermann
 
11 Ban Net Scaler Xa
11 Ban Net Scaler Xa11 Ban Net Scaler Xa
11 Ban Net Scaler Xa
Liudmila Li
 

Similar to Защо Ruby on Rails (20)

P2 P Mobile Advertising And Targeting
P2 P Mobile Advertising And TargetingP2 P Mobile Advertising And Targeting
P2 P Mobile Advertising And Targeting
 
Упаковка и развертывание программ на perl под debian‎
Упаковка и развертывание программ на perl под debian‎Упаковка и развертывание программ на perl под debian‎
Упаковка и развертывание программ на perl под debian‎
 
тупицын Ec2 Rootconf2009
тупицын Ec2 Rootconf2009тупицын Ec2 Rootconf2009
тупицын Ec2 Rootconf2009
 
11 Net Scaler Xa1
11 Net Scaler Xa111 Net Scaler Xa1
11 Net Scaler Xa1
 
Hackday Ml
Hackday MlHackday Ml
Hackday Ml
 
введение в Ror олег андреев
введение в Ror   олег андрееввведение в Ror   олег андреев
введение в Ror олег андреев
 
Основы работы с Memcached
Основы работы с MemcachedОсновы работы с Memcached
Основы работы с Memcached
 
Reification
ReificationReification
Reification
 
20070613 Rit2007 Training
20070613 Rit2007 Training20070613 Rit2007 Training
20070613 Rit2007 Training
 
Что такое ASP.NET MVC?
Что такое ASP.NET MVC?Что такое ASP.NET MVC?
Что такое ASP.NET MVC?
 
Intro To RDBMS And SQL Server 2005 - Svetlin Nakov
Intro To RDBMS And SQL Server 2005 - Svetlin NakovIntro To RDBMS And SQL Server 2005 - Svetlin Nakov
Intro To RDBMS And SQL Server 2005 - Svetlin Nakov
 
Revisited
RevisitedRevisited
Revisited
 
OpenSPARC
OpenSPARCOpenSPARC
OpenSPARC
 
Smashing Rails
Smashing RailsSmashing Rails
Smashing Rails
 
RIA & Silverlight
RIA & SilverlightRIA & Silverlight
RIA & Silverlight
 
Postgre Sql 8 4
Postgre Sql 8 4Postgre Sql 8 4
Postgre Sql 8 4
 
Minsk Jazz 190509 Templ
Minsk Jazz 190509 TemplMinsk Jazz 190509 Templ
Minsk Jazz 190509 Templ
 
OO Design with C++: 1. Inheritance, part 1
OO Design with C++: 1. Inheritance, part 1OO Design with C++: 1. Inheritance, part 1
OO Design with C++: 1. Inheritance, part 1
 
Working With Rails
Working With RailsWorking With Rails
Working With Rails
 
11 Ban Net Scaler Xa
11 Ban Net Scaler Xa11 Ban Net Scaler Xa
11 Ban Net Scaler Xa
 

More from Stefan Kanev

Behavior-Driven Development с RSpec и Cucumber
Behavior-Driven Development с RSpec и CucumberBehavior-Driven Development с RSpec и Cucumber
Behavior-Driven Development с RSpec и Cucumber
Stefan Kanev
 
4. Метапрограмиране
4. Метапрограмиране4. Метапрограмиране
4. Метапрограмиране
Stefan Kanev
 
3. Обекти и класове
3. Обекти и класове3. Обекти и класове
3. Обекти и класове
Stefan Kanev
 
1. Въведение в Ruby
1. Въведение в Ruby1. Въведение в Ruby
1. Въведение в Ruby
Stefan Kanev
 

More from Stefan Kanev (15)

Ruby 0 2012
Ruby 0 2012Ruby 0 2012
Ruby 0 2012
 
Ruby 0
Ruby 0Ruby 0
Ruby 0
 
Защо MongoDB?
Защо MongoDB?Защо MongoDB?
Защо MongoDB?
 
Как блогът ми ме направи по-добър професионалист
Как блогът ми ме направи по-добър професионалистКак блогът ми ме направи по-добър професионалист
Как блогът ми ме направи по-добър професионалист
 
Щастливият програмист 2.0
Щастливият програмист 2.0Щастливият програмист 2.0
Щастливият програмист 2.0
 
Пак ли този Rails?
Пак ли този Rails?Пак ли този Rails?
Пак ли този Rails?
 
The Happy Programmer
The Happy ProgrammerThe Happy Programmer
The Happy Programmer
 
ФМИ Python: Agile & Friends
ФМИ Python: Agile & FriendsФМИ Python: Agile & Friends
ФМИ Python: Agile & Friends
 
Behavior-Driven Development с RSpec и Cucumber
Behavior-Driven Development с RSpec и CucumberBehavior-Driven Development с RSpec и Cucumber
Behavior-Driven Development с RSpec и Cucumber
 
Test-Driven Development + Refactoring
Test-Driven Development + RefactoringTest-Driven Development + Refactoring
Test-Driven Development + Refactoring
 
4. Метапрограмиране
4. Метапрограмиране4. Метапрограмиране
4. Метапрограмиране
 
3. Обекти и класове
3. Обекти и класове3. Обекти и класове
3. Обекти и класове
 
2. Функционални Закачки
2. Функционални Закачки2. Функционални Закачки
2. Функционални Закачки
 
1. Въведение в Ruby
1. Въведение в Ruby1. Въведение в Ruby
1. Въведение в Ruby
 
0. За курса, Ruby и Rails
0. За курса, Ruby и Rails0. За курса, Ruby и Rails
0. За курса, Ruby и Rails
 

Recently uploaded

TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Victor Rentea
 

Recently uploaded (20)

ChatGPT and Beyond - Elevating DevOps Productivity
ChatGPT and Beyond - Elevating DevOps ProductivityChatGPT and Beyond - Elevating DevOps Productivity
ChatGPT and Beyond - Elevating DevOps Productivity
 
CNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In PakistanCNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In Pakistan
 
AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)
AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)
AI+A11Y 11MAY2024 HYDERBAD GAAD 2024 - HelloA11Y (11 May 2024)
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
TrustArc Webinar - Unified Trust Center for Privacy, Security, Compliance, an...
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
 
Quantum Leap in Next-Generation Computing
Quantum Leap in Next-Generation ComputingQuantum Leap in Next-Generation Computing
Quantum Leap in Next-Generation Computing
 
TEST BANK For Principles of Anatomy and Physiology, 16th Edition by Gerard J....
TEST BANK For Principles of Anatomy and Physiology, 16th Edition by Gerard J....TEST BANK For Principles of Anatomy and Physiology, 16th Edition by Gerard J....
TEST BANK For Principles of Anatomy and Physiology, 16th Edition by Gerard J....
 
AI in Action: Real World Use Cases by Anitaraj
AI in Action: Real World Use Cases by AnitarajAI in Action: Real World Use Cases by Anitaraj
AI in Action: Real World Use Cases by Anitaraj
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Six Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal OntologySix Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal Ontology
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
Simplifying Mobile A11y Presentation.pptx
Simplifying Mobile A11y Presentation.pptxSimplifying Mobile A11y Presentation.pptx
Simplifying Mobile A11y Presentation.pptx
 
Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)
 
JohnPollard-hybrid-app-RailsConf2024.pptx
JohnPollard-hybrid-app-RailsConf2024.pptxJohnPollard-hybrid-app-RailsConf2024.pptx
JohnPollard-hybrid-app-RailsConf2024.pptx
 
JavaScript Usage Statistics 2024 - The Ultimate Guide
JavaScript Usage Statistics 2024 - The Ultimate GuideJavaScript Usage Statistics 2024 - The Ultimate Guide
JavaScript Usage Statistics 2024 - The Ultimate Guide
 
Choreo: Empowering the Future of Enterprise Software Engineering
Choreo: Empowering the Future of Enterprise Software EngineeringChoreo: Empowering the Future of Enterprise Software Engineering
Choreo: Empowering the Future of Enterprise Software Engineering
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 

Защо Ruby on Rails