mod_deflate

mod_deflate

mod_deflate is an optional module for the Apache HTTP Server, Apache v2 only. Based on Deflate lossless data compression algorithm that uses a combination of the LZ77 algorithm and Huffman coding.

This module provides the DEFLATE output filter that allows output from Apache HTTP server to be compressed before being sent to the client over the network.

It also provides a filter for decompressing (inflating, uncompressing) a gzip compressed response body [1].

The mod_deflate module does not have a lower bound for file size, so it attempts to compress files that are too small to benefit from compression. This results in files smaller than approximately 120 bytes becoming larger when processed by mod_deflate.

Contents

Compatibility

You can check a server to see if it is sending out compressed data, and compression compatibility of your browser for example here.

When textual content compressed using mod_gzip, it should maintain its MIME-type, according to their recommended media type:

  • HTML: text/html
  • XHTML: application/xhtml+xml
  • CSS: text/css
  • JavaScript: application/x-javascript

Some alternatives

The mod_gzip module is similar to mod_deflate, for Apache v1 and v2.

A mod_gz module was independently developed by Ian Holsman. This module implements a gzip compression filter for Apache 2.0, providing similar functionality to mod_gzip. One important difference between the two modules is that mod_gzip includes its own gzip implementation, whereas mod_gz relies on an external zlib library.

In PHP similar effect achievable for the output of PHP scripts with:

CherryPy offers the Gzip filter [2], which uses the zlib module of Python standard library.

License

The mod_deflate module is part of Apache v2, licensed with Apache License 2.0.

History

Module level content compression for Apache started with mod_gzip, which is an external extension module, since Apache 1.3.

The developers of the Apache 2.0.x servers have included mod_deflate in the codebase for the server to perform a similar GZIP-encoding function. Early versions provided lesser amount of compression than mod_gzip [3].

Starting with Apache 2.0.45, the compression level of mod_deflate is configurable using the DeflateCompressionLevel directive. This directive accepts values between 1 (fastest compression speed, lowest compression ratio) and 9 (slowest compression speed, highest compression ratio), with the default value being 6. This change made the compression in mod_deflate comparable to mod_gzip out of the box.

See also

  • HTTP compression
  • Some general purpose Apache modules
  • Some programming language interfaces for Apache

External links

Notes


Wikimedia Foundation. 2010.

Игры ⚽ Нужно сделать НИР?

Look at other dictionaries:

  • HTTP compression — is a capability built into both web servers and web browsers, to make better use of available bandwidth. HTTP protocol data is compressed before it is sent from the server: compliant browsers will announce what methods are supported to the server …   Wikipedia

  • mod_ssl — is an optional module for the Apache HTTP Server. Provides strong cryptography for the Apache v1.3 and v2 webserver via the Secure Sockets Layer (SSL v2/v3) and Transport Layer Security (TLS v1) cryptographic protocols by the help of the Open… …   Wikipedia

  • Lighttpd — Infobox Software name = lighttpd caption = developer = Jan Kneschke released = ? frequently updated = yes programming language = C operating system = Cross platform language = English genre = Web server license = BSD licenses website =… …   Wikipedia

  • LigHTTPD — Entwickler: Jan Kneschke Aktuelle Version: 1.4.22 (7. März 2009) Betriebssystem …   Deutsch Wikipedia

  • LightTPD — Entwickler: Jan Kneschke Aktuelle Version: 1.4.22 (7. März 2009) Betriebssystem …   Deutsch Wikipedia

  • Lighttpd — Entwickler Jan Kneschke Aktuelle Version 1.4.29 (3. Juli 2011) Betriebssystem …   Deutsch Wikipedia

  • Lighty — Lighttpd Entwickler: Jan Kneschke Aktuelle Version: 1.4.22 (7. März 2009) Betriebssystem …   Deutsch Wikipedia

  • Servidor HTTP Apache — Apache Desarrollador Apache Software Foundation http://httpd.apache.org …   Wikipedia Español

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”