AmmarkoV / AmmarServer

A lightweight http server for linux
Other
13 stars 5 forks source link

Add Gzip compression #12

Open AmmarkoV opened 11 years ago

AmmarkoV commented 11 years ago

Add Gzip compression on text files to both reduce memory used by the cache but also reduce the bandwidth consumed on the upload channel of the webserver..!

AmmarkoV commented 11 years ago

The project now uses zlib and can "in theory" produce compressed copies of the data to be served.. What is not implemented yet is a list of file types that are not worth beeing compressed ( zip , jpg , mp4 etc ) and per spec responses with all the headers that are needed for most browsers..! Also after some careful examination ( and although gzip specs are clearer ) it may be better to use the standalone deflate compression scheme instead of the most expensive gzip one ..