MmapHandler - Example Apache handler using Apache::Mmap
<Files ~ "/some/htdocs/dir/images/.*(gif|jpe?g|png)$"> SetHandler perl-script PerlHandler MmapHandler </Files>
This module is an example handler showing how Apache::Mmap can be used. Any file requested will be mmap'd into the httpd's memory on the first request. Subsequent requests will simply send the version already in memory.
If you want to handle file types other than the big three image files, add lines which set
$ctype in the
handler sub correctly.
Place lines similar to those shown above in your Apache config.
Mike Fletcher, email@example.com
Apache::Mmap(3), Apache(3), mod_perl(3), mmap(2), perl(1).