Share on Facebook Share on Twitter Email
Answers.com

Rack

 
Wikipedia: Rack (web server interface)
Rack, a Ruby Webserver Interface
Rack-logo.png
Stable release 1.0.0 / 2009-05-25; 6 months ago
Operating system Cross-platform
Type Middleware
License MIT License
Website http://rack.rubyforge.org/

Rack provides a minimal, modular and adaptable interface for developing web applications in Ruby. By wrapping HTTP requests and responses in the simplest way possible, it unifies and distills the API for web servers, web frameworks, and software in between (the so-called middleware) into a single method call.

Example Application

A Rack-compatible "Hello World" application in Ruby syntax:

require 'rack'
app = Rack::Builder.app do 
  lambda do |env|
    body = "Hello, World!"
    [200, {"Content-Type" => "text/plain", "Content-Length" => body.length.to_s}, [body]]
  end
end

External links



Search unanswered questions...
Enter a question here...
Search: All sources Community Q&A Reference topics
Shopping: Rack
Top
 
 
Learn More
rack folder (in marketing)
penrack
hayrack

What is a cooling rack? Read answer...
What is a wok rack? Read answer...
What is staining rack? Read answer...

Help us answer these
What is the function of a rack?
What is a riddling rack?
What is rack end?

Post a question - any question - to the WikiAnswers community:

 

Copyrights:

Wikipedia. This article is licensed under the Creative Commons Attribution/Share-Alike License. It uses material from the Wikipedia article "Rack (web server interface)" Read more