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.
$ctype
handler
Place lines similar to those shown above in your Apache config.
Mike Fletcher, lemur1@mindspring.com
Apache::Mmap(3), Apache(3), mod_perl(3), mmap(2), perl(1).
To install Apache::Mmap, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Apache::Mmap
CPAN shell
perl -MCPAN -e shell install Apache::Mmap
For more information on module installation, please visit the detailed CPAN module installation guide.