diff options
author | Oscar Del Ben <oscar@oscardelben.com> | 2013-02-02 19:50:01 -0800 |
---|---|---|
committer | James Tucker <jftucker@gmail.com> | 2013-02-07 18:31:44 -0800 |
commit | ebd47ba3fa12a60212b6dab9ce8c4b6eefe56332 (patch) | |
tree | 3c3faed9259c3ef913019cd18eea37dab58a8752 | |
parent | 6adb0a51bc68ef3c955c10603ebc49439cd6790f (diff) | |
download | rack-ebd47ba3fa12a60212b6dab9ce8c4b6eefe56332.tar.gz |
Document Rack::Deflater
-rw-r--r-- | lib/rack/deflater.rb | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/lib/rack/deflater.rb b/lib/rack/deflater.rb index 9972e63d..2f219f0e 100644 --- a/lib/rack/deflater.rb +++ b/lib/rack/deflater.rb @@ -4,6 +4,18 @@ require "time" # for Time.httpdate require 'rack/utils' module Rack + # This middleware enables compression of http responses. + # + # Currently supported compression algorithms: + # + # * gzip + # * deflate + # * identity (no transformation) + # + # The middleware automatically detects when compression is supported + # and allowed. For example no transformation is made when a cache + # directive of 'no-transform' is present, or when the response status + # code is one that doesn't allow an entity body. class Deflater def initialize(app) @app = app |