SlideShare ist ein Scribd-Unternehmen logo
1 von 41
“Web development that doesn’t hurt”


Thursday, February 5, 2009
“Faster, Lighter, More Agile”


Thursday, February 5, 2009
Merb == Rails
                      Merb != Rails
                      Rails << Merb

Thursday, February 5, 2009
Merb == Rails


Thursday, February 5, 2009
“Rails is a Model View Controller
             web framework written in Ruby.”




Thursday, February 5, 2009
“Merb is a Model View Controller
           web framework written in Ruby.”




Thursday, February 5, 2009
merb-gen app blog   rails blog
Thursday, February 5, 2009
Merb != Rails


Thursday, February 5, 2009
Merb = Mongrel + erb




Thursday, February 5, 2009
Hey there folks-

                        I'm happy to announce the first useable release of my new pocket-
                                         Merb is a mongrel handler with
                        framework Merb.
                        built in controller and view templating with
                        erb. It has a nice routing system similar to rails but much simpler.
                        It uses some of the code from the camping handler and the rails
                        handler and then some of its own secret sauce
                        to form imho a nice fast little framework.

                                                            -- Ezra Zygmuntowicz, 10-2006




Thursday, February 5, 2009
Merb -= Mongrel
                             Merb -= erb




Thursday, February 5, 2009
Enter Rack
             “Rack provides an minimal interface between webservers
                    supporting Ruby and Ruby frameworks.”




Thursday, February 5, 2009
Camping           Passenger


                             Ramaze            Mongrel


                                        Rack
                              Merb               Thin


                             Sinatra           WEBrick


                                ...               ...

                             Handlers          Adapters


Thursday, February 5, 2009
Rails          Merb

                             ORM     ActiveRecord    Pick one!


                   Test framework     Test::Unit    Don’t care!


                Template language        erb        Your choice!


                      JS framework    Prototype     Whatever!



Thursday, February 5, 2009
rails
                                The full monty under your
                             fingertips with a single command.




Thursday, February 5, 2009
actionmailer

                              actionpack

                              activerecord

                             activeresource

                             activesupport

                                  rails




Thursday, February 5, 2009
merb
                             Small core, build your personal
                               stack with available gems.




Thursday, February 5, 2009
merb-helpers        merb-cache

                                merb-mailer                 merb-assets

                              merb-slices                 merb-action-args

                                              merb-core

                             merb-param-protection         merb-exceptions

                                 merb-auth-core        merb-auth-more

                                        merb-auth-slice-password




Thursday, February 5, 2009
“the framework”
                                   merb-helpers        merb-cache
                                                             - Router
                                                            - Controller
                                merb-mailer                 merb-assets
                                                            - Logger
                                                              - Provide hooks for plugins
                              merb-slices                 merb-action-args

                                              merb-core

                             merb-param-protection         merb-exceptions

                                 merb-auth-core        merb-auth-more

                                        merb-auth-slice-password




Thursday, February 5, 2009
merb-helpers        merb-cache

                                merb-mailer                 merb-assets

                              merb-slices                 merb-action-args

                                              merb-core

                             merb-param-protection         merb-exceptions

                                 merb-auth-core        merb-auth-more

                                        merb-auth-slice-password




Thursday, February 5, 2009
ActionController::Base   ActionMailer::Base




Thursday, February 5, 2009
Merb::AbstractController




                             Merb::Controller                  Merb::MailController




Thursday, February 5, 2009
Plugins

Thursday, February 5, 2009
Gems

Thursday, February 5, 2009
Rails << Merb


Thursday, February 5, 2009
rails-core




Thursday, February 5, 2009
Rails 3

                                  ORM             Pick one!


                              Test framework     Don’t care!


                             Template language   Your choice!


                               JS framework      Whatever!



Thursday, February 5, 2009
Rails 3

                                  ORM             Pick one!


                              Test framework     Don’t care!


                             Template language   Your choice!


                               JS framework      Whatever!



Thursday, February 5, 2009
Rails 3

                                  ORM             Pick one!


                                  Agnosticism!
                              Test framework     Don’t care!


                             Template language   Your choice!


                               JS framework      Whatever!



Thursday, February 5, 2009
Public



                                API
                             With tests to ensure it doesn’t
                              magically change overtime!

Thursday, February 5, 2009
DataMapper




Thursday, February 5, 2009
SELECT * FROM persons WHERE country = 'NL'




Thursday, February 5, 2009
SELECT * FROM persons WHERE country = 'NL'




             AR: Person.find(:all, :conditions => [quot;country = ?quot;, quot;NLquot;])




Thursday, February 5, 2009
SELECT * FROM persons WHERE country = 'NL'




             AR: Person.find(:all, :conditions => [quot;country = ?quot;, quot;NLquot;])



                             DM: Person.all(:country => quot;NLquot;)




Thursday, February 5, 2009
SELECT * FROM persons WHERE age BETWEEN 18
                 AND 21 ORDER BY AGE DESC




Thursday, February 5, 2009
SELECT * FROM persons WHERE age BETWEEN 18
                 AND 21 ORDER BY AGE DESC



       AR: Person.find(:all, :conditions => [quot;age BETWEEN ? AND ?quot;, 18,
               21], :order => quot;age DESCquot;) # => :( SQL fragments!




Thursday, February 5, 2009
SELECT * FROM persons WHERE age BETWEEN 18
                 AND 21 ORDER BY AGE DESC



       AR: Person.find(:all, :conditions => [quot;age BETWEEN ? AND ?quot;, 18,
               21], :order => quot;age DESCquot;) # => :( SQL fragments!



   DM: Person.all(:age.gt => 18, :age.lt => 21, :order => [:age.desc])




Thursday, February 5, 2009
Nice: “strategic eager loading”
                                    100 zoos; 250 exhibits

                zoos = Zoo.all
                zoos.each do |zoo|
                  zoo.exhibits.each do |exhibit|
                    puts quot;Zoo: #{zoo.name}, Exhibit: #{exhibit.name}quot;
                  end
                end


                                                       Queries
                             ActiveRecord
                             DataMapper


Thursday, February 5, 2009
Nice: “strategic eager loading”
                                    100 zoos; 250 exhibits

                zoos = Zoo.all
                zoos.each do |zoo|
                  zoo.exhibits.each do |exhibit|
                    puts quot;Zoo: #{zoo.name}, Exhibit: #{exhibit.name}quot;
                  end
                end


                                                       Queries
                                                        101
                             ActiveRecord
                             DataMapper


Thursday, February 5, 2009
Nice: “strategic eager loading”
                                    100 zoos; 250 exhibits

                zoos = Zoo.all
                zoos.each do |zoo|
                  zoo.exhibits.each do |exhibit|
                    puts quot;Zoo: #{zoo.name}, Exhibit: #{exhibit.name}quot;
                  end
                end


                                                       Queries
                                                        101
                             ActiveRecord
                                                         2
                             DataMapper


Thursday, February 5, 2009
Associations


    class Zoo
      include DataMapper::Resource
                                                  class Zoo < ActiveRecord::Base
      belongs_to :owner                             belongs_to :owner
      has 1, :cafetaria                             has_one :cafetaria
      has n, :animals                               has_many :animals
      has n, :donors, :through => Resource          has_and_belongs_to_many :donors
      has n, :zookeepers, :through => :agencies     has_many :zookeepers, :through => :agencies
    end                                           end




Thursday, February 5, 2009

Weitere ähnliche Inhalte

Andere mochten auch

Steve connolly pilot presentation for madrid
Steve connolly pilot presentation for madridSteve connolly pilot presentation for madrid
Steve connolly pilot presentation for madridcpremolino
 
Ball de gitanes per carnetoltes: recuperem la tradició!
Ball de gitanes per carnetoltes: recuperem la tradició!Ball de gitanes per carnetoltes: recuperem la tradició!
Ball de gitanes per carnetoltes: recuperem la tradició!gitanesantaeuliaron
 
Horizon Report Presentation Innovation Day 2014
Horizon Report Presentation Innovation Day 2014Horizon Report Presentation Innovation Day 2014
Horizon Report Presentation Innovation Day 2014National University
 
10 Thought Leaders Boiled Down 1204103143410416 4
10 Thought Leaders Boiled Down 1204103143410416 410 Thought Leaders Boiled Down 1204103143410416 4
10 Thought Leaders Boiled Down 1204103143410416 4kevin haynes
 
Legacy Case Study Garry Wilkinson 091009
Legacy  Case  Study  Garry  Wilkinson 091009Legacy  Case  Study  Garry  Wilkinson 091009
Legacy Case Study Garry Wilkinson 091009Graham Richards
 
Sandip Mukherjee CV
Sandip Mukherjee CVSandip Mukherjee CV
Sandip Mukherjee CVsandipm
 
Class Guidelines and Procedures
Class Guidelines and ProceduresClass Guidelines and Procedures
Class Guidelines and ProceduresCarlos Vázquez
 
Building research student communities: is there a role for library and learni...
Building research student communities: is there a role for library and learni...Building research student communities: is there a role for library and learni...
Building research student communities: is there a role for library and learni...Jo Webb
 
Matt King Email Marketing Core Concepts And Best Practice (Sept09)
Matt King Email Marketing   Core Concepts And Best Practice (Sept09)Matt King Email Marketing   Core Concepts And Best Practice (Sept09)
Matt King Email Marketing Core Concepts And Best Practice (Sept09)bestmarketing
 
Social Networks - Social Networking
Social Networks - Social NetworkingSocial Networks - Social Networking
Social Networks - Social Networkingmuehl
 
Legacies From Scratch Presentation Sheffield Hallam Sept 09
Legacies From Scratch Presentation   Sheffield Hallam Sept 09Legacies From Scratch Presentation   Sheffield Hallam Sept 09
Legacies From Scratch Presentation Sheffield Hallam Sept 09Graham Richards
 
In library school or job hunting: tips & tricks to build up your professional...
In library school or job hunting: tips & tricks to build up your professional...In library school or job hunting: tips & tricks to build up your professional...
In library school or job hunting: tips & tricks to build up your professional...Lisa Chow
 
AsstrA Animals English 2009 V2
AsstrA Animals English 2009 V2AsstrA Animals English 2009 V2
AsstrA Animals English 2009 V2Pavel Red'ko
 
4 SITE DIGITAL MARKETING PRESENTATION
4 SITE DIGITAL MARKETING PRESENTATION4 SITE DIGITAL MARKETING PRESENTATION
4 SITE DIGITAL MARKETING PRESENTATION4 Site Digital
 
Reconocimientos al alumnado IES ITABA 2011-2012
Reconocimientos al alumnado IES ITABA 2011-2012Reconocimientos al alumnado IES ITABA 2011-2012
Reconocimientos al alumnado IES ITABA 2011-2012iesitaba
 

Andere mochten auch (20)

Steve connolly pilot presentation for madrid
Steve connolly pilot presentation for madridSteve connolly pilot presentation for madrid
Steve connolly pilot presentation for madrid
 
Ball de gitanes per carnetoltes: recuperem la tradició!
Ball de gitanes per carnetoltes: recuperem la tradició!Ball de gitanes per carnetoltes: recuperem la tradició!
Ball de gitanes per carnetoltes: recuperem la tradició!
 
Horizon Report Presentation Innovation Day 2014
Horizon Report Presentation Innovation Day 2014Horizon Report Presentation Innovation Day 2014
Horizon Report Presentation Innovation Day 2014
 
10 Thought Leaders Boiled Down 1204103143410416 4
10 Thought Leaders Boiled Down 1204103143410416 410 Thought Leaders Boiled Down 1204103143410416 4
10 Thought Leaders Boiled Down 1204103143410416 4
 
Legacy Case Study Garry Wilkinson 091009
Legacy  Case  Study  Garry  Wilkinson 091009Legacy  Case  Study  Garry  Wilkinson 091009
Legacy Case Study Garry Wilkinson 091009
 
Sandip Mukherjee CV
Sandip Mukherjee CVSandip Mukherjee CV
Sandip Mukherjee CV
 
Class Guidelines and Procedures
Class Guidelines and ProceduresClass Guidelines and Procedures
Class Guidelines and Procedures
 
Building research student communities: is there a role for library and learni...
Building research student communities: is there a role for library and learni...Building research student communities: is there a role for library and learni...
Building research student communities: is there a role for library and learni...
 
Maria Seredyszyn Hames Country
Maria Seredyszyn Hames CountryMaria Seredyszyn Hames Country
Maria Seredyszyn Hames Country
 
The Copywriter's Handbook 文案创作完全手册 Chap1
The Copywriter's Handbook 文案创作完全手册 Chap1The Copywriter's Handbook 文案创作完全手册 Chap1
The Copywriter's Handbook 文案创作完全手册 Chap1
 
Matt King Email Marketing Core Concepts And Best Practice (Sept09)
Matt King Email Marketing   Core Concepts And Best Practice (Sept09)Matt King Email Marketing   Core Concepts And Best Practice (Sept09)
Matt King Email Marketing Core Concepts And Best Practice (Sept09)
 
Social Networks - Social Networking
Social Networks - Social NetworkingSocial Networks - Social Networking
Social Networks - Social Networking
 
Guión 24 enero
Guión 24 eneroGuión 24 enero
Guión 24 enero
 
Go Zone Presentation
Go Zone PresentationGo Zone Presentation
Go Zone Presentation
 
Legacies From Scratch Presentation Sheffield Hallam Sept 09
Legacies From Scratch Presentation   Sheffield Hallam Sept 09Legacies From Scratch Presentation   Sheffield Hallam Sept 09
Legacies From Scratch Presentation Sheffield Hallam Sept 09
 
In library school or job hunting: tips & tricks to build up your professional...
In library school or job hunting: tips & tricks to build up your professional...In library school or job hunting: tips & tricks to build up your professional...
In library school or job hunting: tips & tricks to build up your professional...
 
AsstrA Animals English 2009 V2
AsstrA Animals English 2009 V2AsstrA Animals English 2009 V2
AsstrA Animals English 2009 V2
 
Best of Web 2.0
Best  of Web 2.0 Best  of Web 2.0
Best of Web 2.0
 
4 SITE DIGITAL MARKETING PRESENTATION
4 SITE DIGITAL MARKETING PRESENTATION4 SITE DIGITAL MARKETING PRESENTATION
4 SITE DIGITAL MARKETING PRESENTATION
 
Reconocimientos al alumnado IES ITABA 2011-2012
Reconocimientos al alumnado IES ITABA 2011-2012Reconocimientos al alumnado IES ITABA 2011-2012
Reconocimientos al alumnado IES ITABA 2011-2012
 

Ähnlich wie Rails and Merb

Merb The Super Bike Of Frameworks
Merb The Super Bike Of FrameworksMerb The Super Bike Of Frameworks
Merb The Super Bike Of FrameworksRowan Hick
 
Caching, Memcached And Rails
Caching, Memcached And RailsCaching, Memcached And Rails
Caching, Memcached And Railsguestac752c
 
Merb presentation at ORUG
Merb presentation at ORUGMerb presentation at ORUG
Merb presentation at ORUGMatt Aimonetti
 
Developing Cocoa Applications with macRuby
Developing Cocoa Applications with macRubyDeveloping Cocoa Applications with macRuby
Developing Cocoa Applications with macRubyBrendan Lim
 
程序员0806期敏捷与性能的博弈
程序员0806期敏捷与性能的博弈程序员0806期敏捷与性能的博弈
程序员0806期敏捷与性能的博弈Jesse Cai
 
Ruby and Rails for womens
Ruby and Rails for womensRuby and Rails for womens
Ruby and Rails for womenss4nx
 
The Future of JRuby - Baruco 2013
The Future of JRuby - Baruco 2013The Future of JRuby - Baruco 2013
The Future of JRuby - Baruco 2013Charles Nutter
 
Building Apis That Rock
Building Apis That RockBuilding Apis That Rock
Building Apis That RockJeff Eaton
 

Ähnlich wie Rails and Merb (10)

Merb The Super Bike Of Frameworks
Merb The Super Bike Of FrameworksMerb The Super Bike Of Frameworks
Merb The Super Bike Of Frameworks
 
Caching, Memcached And Rails
Caching, Memcached And RailsCaching, Memcached And Rails
Caching, Memcached And Rails
 
Merb presentation at ORUG
Merb presentation at ORUGMerb presentation at ORUG
Merb presentation at ORUG
 
ERECOMPI
ERECOMPIERECOMPI
ERECOMPI
 
Developing Cocoa Applications with macRuby
Developing Cocoa Applications with macRubyDeveloping Cocoa Applications with macRuby
Developing Cocoa Applications with macRuby
 
Ruby on rails
Ruby on railsRuby on rails
Ruby on rails
 
程序员0806期敏捷与性能的博弈
程序员0806期敏捷与性能的博弈程序员0806期敏捷与性能的博弈
程序员0806期敏捷与性能的博弈
 
Ruby and Rails for womens
Ruby and Rails for womensRuby and Rails for womens
Ruby and Rails for womens
 
The Future of JRuby - Baruco 2013
The Future of JRuby - Baruco 2013The Future of JRuby - Baruco 2013
The Future of JRuby - Baruco 2013
 
Building Apis That Rock
Building Apis That RockBuilding Apis That Rock
Building Apis That Rock
 

Kürzlich hochgeladen

Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?Antenna Manufacturer Coco
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slidevu2urc
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessPixlogix Infotech
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEarley Information Science
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)wesley chun
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 

Kürzlich hochgeladen (20)

Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 

Rails and Merb

  • 1. “Web development that doesn’t hurt” Thursday, February 5, 2009
  • 2. “Faster, Lighter, More Agile” Thursday, February 5, 2009
  • 3. Merb == Rails Merb != Rails Rails << Merb Thursday, February 5, 2009
  • 4. Merb == Rails Thursday, February 5, 2009
  • 5. “Rails is a Model View Controller web framework written in Ruby.” Thursday, February 5, 2009
  • 6. “Merb is a Model View Controller web framework written in Ruby.” Thursday, February 5, 2009
  • 7. merb-gen app blog rails blog Thursday, February 5, 2009
  • 8. Merb != Rails Thursday, February 5, 2009
  • 9. Merb = Mongrel + erb Thursday, February 5, 2009
  • 10. Hey there folks- I'm happy to announce the first useable release of my new pocket- Merb is a mongrel handler with framework Merb. built in controller and view templating with erb. It has a nice routing system similar to rails but much simpler. It uses some of the code from the camping handler and the rails handler and then some of its own secret sauce to form imho a nice fast little framework. -- Ezra Zygmuntowicz, 10-2006 Thursday, February 5, 2009
  • 11. Merb -= Mongrel Merb -= erb Thursday, February 5, 2009
  • 12. Enter Rack “Rack provides an minimal interface between webservers supporting Ruby and Ruby frameworks.” Thursday, February 5, 2009
  • 13. Camping Passenger Ramaze Mongrel Rack Merb Thin Sinatra WEBrick ... ... Handlers Adapters Thursday, February 5, 2009
  • 14. Rails Merb ORM ActiveRecord Pick one! Test framework Test::Unit Don’t care! Template language erb Your choice! JS framework Prototype Whatever! Thursday, February 5, 2009
  • 15. rails The full monty under your fingertips with a single command. Thursday, February 5, 2009
  • 16. actionmailer actionpack activerecord activeresource activesupport rails Thursday, February 5, 2009
  • 17. merb Small core, build your personal stack with available gems. Thursday, February 5, 2009
  • 18. merb-helpers merb-cache merb-mailer merb-assets merb-slices merb-action-args merb-core merb-param-protection merb-exceptions merb-auth-core merb-auth-more merb-auth-slice-password Thursday, February 5, 2009
  • 19. “the framework” merb-helpers merb-cache - Router - Controller merb-mailer merb-assets - Logger - Provide hooks for plugins merb-slices merb-action-args merb-core merb-param-protection merb-exceptions merb-auth-core merb-auth-more merb-auth-slice-password Thursday, February 5, 2009
  • 20. merb-helpers merb-cache merb-mailer merb-assets merb-slices merb-action-args merb-core merb-param-protection merb-exceptions merb-auth-core merb-auth-more merb-auth-slice-password Thursday, February 5, 2009
  • 21. ActionController::Base ActionMailer::Base Thursday, February 5, 2009
  • 22. Merb::AbstractController Merb::Controller Merb::MailController Thursday, February 5, 2009
  • 25. Rails << Merb Thursday, February 5, 2009
  • 27. Rails 3 ORM Pick one! Test framework Don’t care! Template language Your choice! JS framework Whatever! Thursday, February 5, 2009
  • 28. Rails 3 ORM Pick one! Test framework Don’t care! Template language Your choice! JS framework Whatever! Thursday, February 5, 2009
  • 29. Rails 3 ORM Pick one! Agnosticism! Test framework Don’t care! Template language Your choice! JS framework Whatever! Thursday, February 5, 2009
  • 30. Public API With tests to ensure it doesn’t magically change overtime! Thursday, February 5, 2009
  • 32. SELECT * FROM persons WHERE country = 'NL' Thursday, February 5, 2009
  • 33. SELECT * FROM persons WHERE country = 'NL' AR: Person.find(:all, :conditions => [quot;country = ?quot;, quot;NLquot;]) Thursday, February 5, 2009
  • 34. SELECT * FROM persons WHERE country = 'NL' AR: Person.find(:all, :conditions => [quot;country = ?quot;, quot;NLquot;]) DM: Person.all(:country => quot;NLquot;) Thursday, February 5, 2009
  • 35. SELECT * FROM persons WHERE age BETWEEN 18 AND 21 ORDER BY AGE DESC Thursday, February 5, 2009
  • 36. SELECT * FROM persons WHERE age BETWEEN 18 AND 21 ORDER BY AGE DESC AR: Person.find(:all, :conditions => [quot;age BETWEEN ? AND ?quot;, 18, 21], :order => quot;age DESCquot;) # => :( SQL fragments! Thursday, February 5, 2009
  • 37. SELECT * FROM persons WHERE age BETWEEN 18 AND 21 ORDER BY AGE DESC AR: Person.find(:all, :conditions => [quot;age BETWEEN ? AND ?quot;, 18, 21], :order => quot;age DESCquot;) # => :( SQL fragments! DM: Person.all(:age.gt => 18, :age.lt => 21, :order => [:age.desc]) Thursday, February 5, 2009
  • 38. Nice: “strategic eager loading” 100 zoos; 250 exhibits zoos = Zoo.all zoos.each do |zoo| zoo.exhibits.each do |exhibit| puts quot;Zoo: #{zoo.name}, Exhibit: #{exhibit.name}quot; end end Queries ActiveRecord DataMapper Thursday, February 5, 2009
  • 39. Nice: “strategic eager loading” 100 zoos; 250 exhibits zoos = Zoo.all zoos.each do |zoo| zoo.exhibits.each do |exhibit| puts quot;Zoo: #{zoo.name}, Exhibit: #{exhibit.name}quot; end end Queries 101 ActiveRecord DataMapper Thursday, February 5, 2009
  • 40. Nice: “strategic eager loading” 100 zoos; 250 exhibits zoos = Zoo.all zoos.each do |zoo| zoo.exhibits.each do |exhibit| puts quot;Zoo: #{zoo.name}, Exhibit: #{exhibit.name}quot; end end Queries 101 ActiveRecord 2 DataMapper Thursday, February 5, 2009
  • 41. Associations class Zoo include DataMapper::Resource class Zoo < ActiveRecord::Base belongs_to :owner belongs_to :owner has 1, :cafetaria has_one :cafetaria has n, :animals has_many :animals has n, :donors, :through => Resource has_and_belongs_to_many :donors has n, :zookeepers, :through => :agencies has_many :zookeepers, :through => :agencies end end Thursday, February 5, 2009

Hinweis der Redaktion