Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 77 lines (62 sloc) 3.52 kb
3560ac0 Ryan Tomayko Flesh out README a bit; rename to README.rdoc
rtomayko authored
1 = Contributed Rack Middleware and Utilities
2
3 This package includes a variety of add-on components for Rack, a Ruby web server
4 interface:
5
6 * Rack::ETag - Automatically sets the ETag header on all String bodies.
7 * Rack::JSONP - Adds JSON-P support by stripping out the callback param
8 and padding the response with the appropriate callback format.
9 * Rack::LighttpdScriptNameFix - Fixes how lighttpd sets the SCRIPT_NAME
10 and PATH_INFO variables in certain configurations.
11 * Rack::Locale - Detects the client locale using the Accept-Language request
12 header and sets a rack.locale variable in the environment.
13 * Rack::MailExceptions - Rescues exceptions raised from the app and
14 sends a useful email with the exception, stacktrace, and contents of the
15 environment.
86a2ced Mislav Marohnić Add Rack::NestedParams; based on Rails UrlEncodedPairParser
mislav authored
16 * Rack::NestedParams - parses form params with subscripts (e.g., * "post[title]=Hello")
17 into a nested/recursive Hash structure (based on Rails' implementation).
3560ac0 Ryan Tomayko Flesh out README a bit; rename to README.rdoc
rtomayko authored
18 * Rack::PostBodyContentTypeParser - Adds support for JSON request bodies. The
19 Rack parameter hash is populated by deserializing the JSON data provided in
20 the request body when the Content-Type is application/json.
b1a4195 Ryan Tomayko Rack::ProcTitle - request status in $0
rtomayko authored
21 * Rack::ProcTitle - Displays request information in process title ($0) for
22 monitoring/inspection with ps(1).
3560ac0 Ryan Tomayko Flesh out README a bit; rename to README.rdoc
rtomayko authored
23 * Rack::Profiler - Uses ruby-prof to measure request time.
24 * Rack::Sendfile - Enables X-Sendfile support for bodies that can be served
25 from file.
4d28e24 Joshua Peek Add Signals middleware
josh authored
26 * Rack::Signals - Installs signal handlers that are safely processed after
27 a request
3560ac0 Ryan Tomayko Flesh out README a bit; rename to README.rdoc
rtomayko authored
28 * Rack::TimeZone - Detects the clients timezone using JavaScript and sets
29 a variable in Rack's environment with the offset from UTC.
ec0fb58 Pratik Add Rack::Callbacks. Example :
lifo authored
30 * Rack::Evil - Lets the rack application return a response to the client from any place.
31 * Rack::Callbacks - Implements DLS for pure before/after filter like Middlewares.
01533a8 Jon Crosby Add Rack::Config
jcrosby authored
32 * Rack::Config - Shared configuration for cooperative middleware.
31370b7 Jon Crosby Add Rack::NotFound
jcrosby authored
33 * Rack::NotFound - A default 404 application.
fe510ef Cameron Walters (cee-dub) Add Rack::CSSHTTPRequest middleware
cee-dub authored
34 * Rack::CSSHTTPRequest - Adds CSSHTTPRequest support by encoding responses as
35 CSS for cross-site AJAX-style data loading
82951d3 TJ Holowaychuk Added Rack::Deflect - DOS protection middleware
tj authored
36 * Rack::Deflect - Helps protect against DoS attacks.
43a508f Jeremy Evans Add Rack::RelativeRedirect
jeremyevans authored
37 * Rack::ResponseCache - Caches responses to requests without query strings
38 to Disk or a user provider Ruby object. Similar to Rails' page caching.
39 * Rack::RelativeRedirect - Transforms relative paths in redirects to
40 absolute URLs.
3e1d5f2 Harry Vangberg Rack::Backstage - maintenance page middleware
vangberg authored
41 * Rack::Backstage - Returns content of specified file if it exists, which makes
42 it convenient for putting up maintenance pages.
fae344f Martin Fix README typo (Rack::AcceptFormat)
mynyml authored
43 * Rack::AcceptFormat - Adds a format extension at the end of the URI when there is none, corresponding to the mime-type given in the Accept HTTP header.
988cd66 Jon Crosby Add Rack::HostMeta
jcrosby authored
44 * Rack::HostMeta - Configures /host-meta using a block
94fde2b Joshua Peek Rack::Cookies
josh authored
45 * Rack::Cookies - Adds simple cookie jar hash to env
3560ac0 Ryan Tomayko Flesh out README a bit; rename to README.rdoc
rtomayko authored
46
47 === Use
48
49 Git is the quickest way to the rack-contrib sources:
50
b5218fe Ryan Tomayko README and gemspec update (project URL change, mostly)
rtomayko authored
51 git clone git://github.com/rack/rack-contrib.git
3560ac0 Ryan Tomayko Flesh out README a bit; rename to README.rdoc
rtomayko authored
52
53 Gems are currently available from GitHub clones:
54
b5218fe Ryan Tomayko README and gemspec update (project URL change, mostly)
rtomayko authored
55 gem install rack-rack-contrib --source=http://gems.github.com/
3560ac0 Ryan Tomayko Flesh out README a bit; rename to README.rdoc
rtomayko authored
56
57 Requiring 'rack/contrib' will add autoloads to the Rack modules for all of the
58 components included. The following example shows what a simple rackup
59 (+config.ru+) file might look like:
60
61 require 'rack'
62 require 'rack/contrib'
63
64 use Rack::Profiler if ENV['RACK_ENV'] == 'development'
65
66 use Rack::ETag
67 use Rack::MailExceptions
68
69 run theapp
70
71 === Links
72
b5218fe Ryan Tomayko README and gemspec update (project URL change, mostly)
rtomayko authored
73 rack-contrib on GitHub:: <http://github.com/rack/rack-contrib>
3560ac0 Ryan Tomayko Flesh out README a bit; rename to README.rdoc
rtomayko authored
74 Rack:: <http://rack.rubyforge.org/>
b5218fe Ryan Tomayko README and gemspec update (project URL change, mostly)
rtomayko authored
75 Rack On GitHub:: <http://github.org/rack/rack>
3560ac0 Ryan Tomayko Flesh out README a bit; rename to README.rdoc
rtomayko authored
76 rack-devel mailing list:: <http://groups.google.com/group/rack-devel>
Something went wrong with that request. Please try again.