Why Merb? by Kim Dalsgaard = What is Merb? Web framework for the VC in MVC Thread-safe No CGI.rb A small core, enhanced with plug-ins Merb is a hacker's framework Slogan: Stay small - stay hackable (Kitchen sink not included) = Historial facts Started in October 2006 by Ezra Zygmuntowicz Originally designed as a hack for uploading files for Ruby on Rails Used to be Mongrel + Erb Now it is Rack + Templating engine = Filosophy No code is faster than no code Simplicity and clarity trumphs magic every time, so prefer simple code over magic code Don't be clever! = Things I like about Merb Compiled routes Merb::Router.compiled_satement outputs the compiled match method == Controllers Merb render the return value from each action - Opens up for many possibilities - Can return String, IO and Proc objects The rende rmethod returns a string The provides and display methods for rendering objects class Regions < Application provides :yaml, :json def index @regions = Region.all display @regions end end render_then_call - Returns the response, then goes on with other code = Merb is built in top of Rack - Rack provides a minimal interface between apps and servers - Rack takes in the environment and returns status, headers and body http://www.merbivore.org Rails is good for full-blown apps Merb is good for minor things, e.g. a json service