Bug #505
closedBuilt in HTTP server in WT and Compression with ZLIB : the need to disable compression for some MIME types
70%
Description
Some times Flash player is not able to play MP3 files when they are compressed with zlib.
Is there a way to use compression with zlib for normal http traffic with built in web server and to disable it for some MIME types : for example : "audio/mpeg", "audio/ogg" ... or for some file extensions "*.mp3" , "*.ogg" , "*.jpg" ... etc ...
thanks in advance for your help
Updated by Thomas Suckow almost 15 years ago
The Wt internal http server should not be gzip compressing non-text files. http/Reply.C:267 has a list of the MIME types that WILL be compressed. I would be interested to know what MIME type Wt is serving the MP3 as. Can you check that, the easiest way is probably with Wireshark.
Updated by Koen Deforche almost 15 years ago
- Status changed from New to InProgress
- Assignee set to Wim Dumon
Hey,
It seems that the problem is that mp3 is not handled as a known mime-type (MimeTypes.C), and the default mime-type it choses is text/plain which is going to trigger compression.
This probably means two fixes are needed:
- add "mp3" as mime-type (or rather move mime-types into a configuration file)
- default to a mime-type which does not trigger compression
Regards,
koen
Updated by Thomas Suckow almost 15 years ago
The default should probably be application/octet-stream (Arbitrary binary data)
Updated by Koen Deforche almost 15 years ago
- % Done changed from 0 to 70
Partially resolved: we did not implement mime-types as a configuration file.
Updated by Koen Deforche almost 12 years ago
- Status changed from InProgress to Resolved
Updated by Koen Deforche almost 12 years ago
- Status changed from Resolved to Closed